test(floor): the L6 projectRoot() test passes on macOS and exercises CLAUDE_PROJECT_DIR (6.32.1) - #296
Merged
Conversation
…CLAUDE_PROJECT_DIR (6.32.1) On macOS os.tmpdir() is under /var, a symlink to /private/var. projectRoot() walks up from process.cwd(), which the OS reports resolved, and resolves CLAUDE_PROJECT_DIR with realpathSync, as the hooks' workTreeRoot() does. The test compared that with the unresolved mkdtemp path, so it failed locally on macOS and passed on Linux CI. run-marker.mjs is unchanged. The fixture also held a .git, which stops the walk on its own, so the CLAUDE_PROJECT_DIR assertion held with the variable unset (measured). The test now runs three phases on one fixture: no stop (a negative control), then CLAUDE_PROJECT_DIR alone, then .git alone. Deleting either stop from a copy of run-marker.mjs fails its phase. Every merge to main is a release, so this ships as 6.32.1 (SKILLS_VERSION, README badge, CHANGELOG section). MIN_CLI is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
Summary
The 6.31.2 test
★ L6: projectRoot() follows CLAUDE_PROJECT_DIR when cwd is a subdirectoryfailed on macOS:os.tmpdir()is under/var, a symlink to/private/var.projectRoot()walks up fromprocess.cwd(), which the OS reports resolved, and resolvesCLAUDE_PROJECT_DIRwithrealpathSync, as the hooks'workTreeRoot()does. The test compared that with the unresolvedmkdtemppath. Linux CI has no such symlink, so it never failed there.run-marker.mjsis unchanged: the resolved root is correct..git, which stops the walk on its own, so theCLAUDE_PROJECT_DIRassertion held with the variable unset. Measured: with only therealpathSyncfix, the test passed after theCLAUDE_PROJECT_DIRbranch was deleted from a copy ofrun-marker.mjs.realpathSync(root)(the marker check uses the same resolved root) and runs three phases on one fixture: no stop (a negative control, not root),CLAUDE_PROJECT_DIRalone (root), then.gitalone (root). On copies ofrun-marker.mjs, deleting theCLAUDE_PROJECT_DIRstop fails phase 2 and deleting the.gitstop fails phase 3.mainis a release, so this ships as 6.32.1:SKILLS_VERSION, the README badge and a## [6.32.1]CHANGELOG section.MIN_CLIis unchanged.Verification (macOS, rebased on c7449e4)
node --test --test-name-pattern='L6: projectRoot' pharn/floor/run-marker.test.mjs: pass.npm run check: exit 0, 4267/4267 tests, reconcileNO_BASELINE. No nested.claude/worktrees/.npm run check:changelog-entry: GREEN, opens## [6.32.1] - 2026-09-28.🤖 Generated with Claude Code