Title#
feat: BJ-14 — unit tests for BitbucketService and JiraService (#554)
Problem#
BitbucketService and JiraService (BJ-8, BJ-9) shipped without test coverage. Tests are required before the Atlassian integration EPIC can close.
Task / Link#
#554 — BJ-14: Unit tests — Bitbucket + Jira services
Changes#
- Added
src/bitbucket/bitbucket.service.spec.ts— 36 tests covering all 18 public methods - Added
src/jira/jira.service.spec.ts— 26 tests covering all 11 public methods - Happy-path tests assert URL, HTTP method, and request body per method
- Cross-cutting scenarios: 429 Retry-After wait+retry, 401 token refresh+retry, 5xx bubble-up, Bearer auth header from
authProvider.getToken() sleepstubbed in both suites to keep tests fast
Notes#
- Merged to
rc/atlassian-integration(via PR #591); will close #554 when that branch lands on master - Implementation uses
jest.spyOn(globalThis, 'fetch')(consistent with the rest of the codebase) rather thannockas originally specced
Testing#
npm run lint— zero warningsnpm run test— 917/917 tests pass (62 new)npm run build— clean compile