adorsys / adorsys/status-list-server
Update Artillery performance test dependencies, tooling, and scripts
- Linguagem predominante
- Rust
- Estrelas
- 22
- Forks
- 5
- Merge médio
- 2d 11h
- PRs com merge (30d)
- 47
Descrição
## Objective
Upgrade Artillery test dependencies and tooling in `artillery-tests/` to latest versions, fix broken script paths in `package.json`, and ensure token generation and performance test executions work cleanly.
## Context
1. `artillery-tests/package.json` uses outdated dependencies (`artillery` 2.0.27, `jsonwebtoken` 9.0.2, `artillery-plugin-metrics-by-endpoint` 1.21.0).
2. `package.json` contains broken script paths (e.g. `artillery run artillery-tests/stress-test.yml` instead of `./tests/stress-test.yml`), causing commands like `npm run test:stress` to fail when run inside `artillery-tests/`.
3. `scripts/token-generator.js` hardcodes relative paths (`artillery-tests/scripts/...`) rather than resolving paths via `path.join(__dirname, ...)`, causing `ENOENT` errors when executed from different working directories.
## Deliverables
- [x] **Upgrade dependencies:**
- Bump `artillery` to latest
- Bump `jsonwebtoken` to latest
- Bump `artillery-plugin-metrics-by-endpoint` to latest
- Bump `artillery-plugin-statsd` to latest
- [x] **Fix script paths:**
- Update all test commands in `package.json` (`test:load`, `test:stress`, `test:spike`, `test:auth`) to reference `./tests/*.yml`.
- Update report scripts to output to `results/*.json`.
- [x] **Robust path resolution:**
- Update `scripts/token-generator.js` to use `path.join(__dirname, ...)` for `ec-private-key.pem`, `ec-public-key.jwk`, and `test-tokens.json`.
- Replace deprecated `substr()` with `substring()` or `slice()`.
- [x] **Verification:**
- Run `npm install` and verify clean lockfile.
- Run `npm run generate-tokens` and verify tokens are successfully created and written to disk.
- Verify test execution with Artillery.
## Acceptance Criteria
- [x] `npm install` completes cleanly with updated dependencies.
- [x] `npm run generate-tokens` succeeds regardless of whether executed from repo root or `artillery-tests/`.
- [x] All npm scripts in `artillery-tests/package.json` execute without path errors.
Guia de contribuição
Avaliação
Esta issue ainda não foi avaliada.