Repository navigation
Cover the Show changes highlight gates in source CI - #49
Merged
Merged
Conversation
Extracts the PR #45 late before-PDF read guard, displayed-document gate and change-stop page clamp into src/change-highlight-gate.ts and tests them under npm test, so a regression is caught without the native Mac smoke. Claude-Session: https://claude.ai/code/session_01KwQt4pZZ1aiywiemc2AmRv
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.
Requested by Grawish · project thread
Before: the fix for the vanishing "Show changes" highlight (#45) was only checked by the native Mac smoke (
npm run test:pdf-highlight), which ordinary CI does not run. Reverting the guard would passnpm test.After: the three rules that fix relies on are pure functions with source tests, so
npm testfails if any of them regresses. App behaviour is unchanged.How:
src/change-highlight-gate.tsholds the late before-PDF read guard (project id + revision, not the active run), the displayed-document gate, and the change-stop page clamp.App.tsxandPdfPreview.tsxcall them in place of the inline expressions.tests/change-highlight-gate.test.tscovers the late read after the run clears, project switch, newer edit, a different displayed buffer, and page clamping.REMAINING_WORK.mdPDF-02 notes the new coverage.🤖 Generated with Claude Code
https://claude.ai/code/session_01KwQt4pZZ1aiywiemc2AmRv
Generated by Claude Code