Skip to content

test(candidate_me): add regression coverage for ObjectId candidateId filter - #168

Merged
datvt243 merged 1 commit into
stagingfrom
153-critical-candidate-me
Sep 27, 2026
Merged

datvt243 merged 1 commit into
stagingfrom
153-critical-candidate-me

Conversation

@datvt243

Copy link
Copy Markdown
Owner

Summary

Closes #153. The production fix was already live on staging as part of the fix-candidate-me-nosql-filter-collapse pass (issue #135, SEALED 2026-09-19) — handlerGetAboutMe already stringifies the ObjectId _id before filtering CV-section queries by candidateId — but no test ever exercised an ObjectId-typed _id specifically (every existing test used a plain string, which would pass even with the old bug), and the diagram node was never backfilled.

  • src/__tests__/candidate_me/index.test.ts — new describe block using a fake ObjectId-like _id (only a .toString() method, not a string) and asserting every CV-section query receives the stringified candidateId, never the raw object, never silently dropped.
  • agent-hub/: backfilled evidence (implementer + verifier) and sealed node fix-candidate-me-candidateid-not-string.

Commits

  • 0dc9b77 test(candidate_me): add regression coverage for ObjectId candidateId filter

Test plan

  • npm test — 141 passed, 141 total (independently re-run by the verifier subagent)
  • npm run build — clean

🤖 Generated with Claude Code

…filter

Closes #153. The production fix was already live on staging as part of
the fix-candidate-me-nosql-filter-collapse pass (issue #135, SEALED
2026-09-19) — handlerGetAboutMe already stringifies the ObjectId _id
before filtering CV-section queries by candidateId — but no test ever
exercised an ObjectId-typed _id specifically (every existing test used
a plain string, which would pass even with the old bug), and the
diagram node was never backfilled.

- src/__tests__/candidate_me/index.test.ts: new describe block using a
  fake ObjectId-like _id (only a .toString() method, not a string) and
  asserting every CV-section query receives the stringified
  candidateId, never the raw object, never silently dropped.
- agent-hub: backfill evidence (implementer + verifier) and seal node
  fix-candidate-me-candidateid-not-string.

npm test: 141 passed, 141 total (independently re-run by the verifier
subagent, matching exactly). npm run build: clean.

Node: fix-candidate-me-candidateid-not-string (SEALED)
Evidence: agent-hub/evidence/implementer/2026-09-28/fix-candidate-me-candidateid-not-string-plan.md,
agent-hub/evidence/verifier/2026-09-28/fix-candidate-me-candidateid-not-string-seal.md

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@datvt243
datvt243 merged commit 04ccc28 into staging Sep 27, 2026
3 checks passed
@datvt243
datvt243 deleted the 153-critical-candidate-me branch September 27, 2026 18:24
@datvt243 datvt243 mentioned this pull request Sep 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant