test(backend): cover default checker failure paths#1268
Conversation
|
nice failure-path coverage: the lock-already-held case (returns null, doesn't release a lock it never took) and the submission-throws case (batch recorded failed, failedSubmissions 1, lock released once via the finally path) are exactly the paths worth testing, and the asserted log strings match the source. tests pass 3/3. one thing:
rebase and i'll merge. if you want to keep contributing, join us on Telegram: https://t.me/+DOylgFv1jyJlNzM0 |
|
good news: the two default-checker test cases (lock-already-held skip + failed-batch recording) are fine and the pr is mergeable (no conflict). the red backend job isn't your fault, it's failing on prettier/eslint errors in files you never touched (scoreDecayService.ts, rateLimitService.ts, etc.) that are already fixed on the current green main, so your branch is just on a stale base. please rebase and the lint errors should vanish and your tests go green: if you want to keep contributing, join us on Telegram: https://t.me/+DOylgFv1jyJlNzM0 |
Summary
Validation
npm test -- --runInBand src/__tests__/defaultChecker.test.tsnpm run typecheckis currently blocked by an existing unrelatedsrc/middleware/auth.tserror:string | undefinedpassed where string/ArrayLike is required.Closes #1204