Repository navigation
test(file-refs): cover unverified/stale state transitions - #68
Merged
Merged
Conversation
The existing tests check the three file-ref states in isolation but never a memory moving between them, which is where the regressions would hide. Add two transition cases (suggested in the #66 discussion): - an untracked path reads as unverified, then becomes tracked and drift-checked once the file is committed and the note re-recorded (a commit alone does not touch stored refs); - a deleted tracked file stays classified as stale, never silently reclassified as unverified. Test-only; no source change.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Merged
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this adds
Follow-up to #66 / #67. Those tests check the three file-ref states in isolation; they never check a memory moving between states, which is where a regression would hide (the upsert flipping
tracked, and the stale-vs-unverified classification staying mutually exclusive as git status changes).Suggested in the #66 discussion. Adds two transition regression cases:
unverified; after the file is committed and the note is re-recorded, it becomestracked = 1, drops the unverified marker, and from then on participates in drift detection. (A commit alone does not touch stored refs — the write path is what re-records, so the test models that step explicitly.)stale(its row is stilltracked = 1) and is never reclassified asunverified.Unchanged
Test-only. No source change, no ranking impact, so no bench run.
npm run cigreen; 274 tests pass (was 272).