Category: Testing & Quality
Difficulty: Medium
Description:
Per the repository pattern the specification mandates, every escrow read and write goes through this file.
Current coverage: 54.05% lines, 51.72% functions, 64% branches.
Around half its methods have never run under test, including several state transitions and the cache invalidation on every write.
Location:
src/escrow/escrow.repository.ts
Example commits:
test(escrow): cover the untested paths in escrow.repository.ts
Acceptance Criteria:
Technical Notes:
Read the implementation before writing assertions and test what it does, not what you assume. If you find behaviour that looks wrong, say so in the pull request rather than silently changing it.
Before you start
- Setup: CONTRIBUTING.md → Development Setup. Use Node 22 (
nvm use), run npm ci rather than npm install, and run npx prisma generate after installing.
- Tests that authenticate: use
bearer() from test/auth-helper.ts. Sending a bare Stellar address as a bearer token returns 401. See Writing Tests That Need Authentication.
- Branch from the latest
dev and open your pull request against dev, not main. dev is the default branch; main is the released baseline.
Category: Testing & Quality
Difficulty: Medium
Description:
Per the repository pattern the specification mandates, every escrow read and write goes through this file.
Current coverage: 54.05% lines, 51.72% functions, 64% branches.
Around half its methods have never run under test, including several state transitions and the cache invalidation on every write.
Location:
src/escrow/escrow.repository.tsExample commits:
Acceptance Criteria:
markAutoReleaseSubmittingreturns null when already claimednpm run test:covpasses and overall coverage stays at or above 70%npm run lint:checkreports no new errorsTechnical Notes:
Read the implementation before writing assertions and test what it does, not what you assume. If you find behaviour that looks wrong, say so in the pull request rather than silently changing it.
Before you start
nvm use), runnpm cirather thannpm install, and runnpx prisma generateafter installing.bearer()fromtest/auth-helper.ts. Sending a bare Stellar address as a bearer token returns 401. See Writing Tests That Need Authentication.devand open your pull request againstdev, notmain.devis the default branch;mainis the released baseline.