Repository navigation
test: coverage ratchet + renderer hooks + main-process backfill - #47
Conversation
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…acks) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning Review limit reached
Next review available in: 58 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (8)
📝 WalkthroughWalkthroughThe PR upgrades Vitest coverage tooling, configures separate Node and renderer test projects, adds CI coverage enforcement and summaries, introduces typed renderer bridge mocks, and adds broad main-process and React hook test coverage. Testing guidance and project status records are updated. ChangesCoverage and testing
Estimated code review effort: 3 (Moderate) | ~30 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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 |
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/main/actions/project-actions.test.ts`:
- Around line 7-12: Update the execFile mock in the hoisted mocks and the
successful project-opening tests to capture invocation arguments, then assert
the VS Code launch command uses open -a "Visual Studio Code" with the expected
absolute path. Apply the same assertion to the additional success cases
referenced by the comment, while retaining the existing Finder-not-opened
checks.
In `@src/main/lib/abbreviate-home.test.ts`:
- Around line 8-10: Update abbreviateHome to abbreviate only an exact home path
or paths beginning with the home directory followed by a separator; preserve
unrelated paths such as “/Users/mean” unchanged, and add the requested boundary
test alongside “leaves non-home paths untouched.”
In `@src/main/notifications/threshold-notifier.test.ts`:
- Around line 14-16: Update the mock event registration method to store
callbacks only when _event equals "click", ensuring tests fail if production
subscribes to another event. Apply the same event filtering to the additional
mock registration block referenced by the comment.
In `@STATUS.html`:
- Around line 121-122: The “Test coverage” roadmap item in STATUS.html is marked
done before the PR is merged. Change its status from done to user or progress
while review and merge remain pending, then update it to done and remove the
outstanding review/merge action only after merge.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 58d6d681-25a9-41fa-8553-3f3069254c0d
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (28)
.github/workflows/ci.yml.gitignoreCLAUDE.mdSTATUS.htmlpackage.jsonsrc/main/actions/project-actions.test.tssrc/main/lib/abbreviate-home.test.tssrc/main/notifications/threshold-notifier.test.tssrc/main/scanner/scanner.test.tssrc/main/scheduler/scan-scheduler.test.tssrc/main/tray/png-encode.test.tssrc/main/windows/window-utils.test.tssrc/renderer/src/hooks/useAutoHeight.test.tssrc/renderer/src/hooks/useDocker.test.tssrc/renderer/src/hooks/useLicense.test.tssrc/renderer/src/hooks/useLiveProjects/useLiveProjects.test.tssrc/renderer/src/hooks/usePackages.test.tssrc/renderer/src/hooks/usePackagesTab.test.tssrc/renderer/src/hooks/usePackagesTab.tssrc/renderer/src/hooks/usePnpmStore.test.tssrc/renderer/src/hooks/useProjects.test.tssrc/renderer/src/hooks/useScanProgress.test.tssrc/renderer/src/hooks/useSettings.test.tssrc/renderer/src/hooks/useToast.test.tssrc/renderer/src/hooks/useUpdater.test.tssrc/renderer/src/test/mock-clean-bridge.tssrc/renderer/src/test/setup.tsvitest.config.ts
💤 Files with no reviewable changes (1)
- src/renderer/src/hooks/usePackagesTab.ts
…riance) CI (Linux) measures slightly lower coverage than macOS because some platform-dependent branches (path probing etc.) don't execute on Linux. The committed thresholds were locked from macOS-local numbers, so CI was failing on every PR. Lock thresholds to CI's own numbers instead and drop autoUpdate: true, since a local macOS coverage run would otherwise rewrite them back up to macOS values and re-break CI.
…ATUS nit abbreviateHome abbreviated sibling paths sharing the home prefix (/Users/mean with home /Users/me became ~an); now requires an exact match or a /-boundary. Notification mock only records click handlers so a wrong event subscription would fail the test. Coverage roadmap item back to 'user' until the PR merges. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…rerun green Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Implements docs/superpowers/specs/2026-07-29-testing-coverage-design.md:
UI component tests intentionally absent (Storybook owns UI). E2E deferred per spec.
🤖 Generated with Claude Code
Summary by CodeRabbit
Quality Improvements
Chores
Documentation