[ef-18] test: add unit tests for preuninstall lifecycle script#19
Conversation
Covers hook removal from all three Claude settings scopes (user, project, local), legacy hook detection, empty-structure cleanup, graceful error handling, dev-context guard, and telemetry payload. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Free Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughA comprehensive test suite for the Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes Poem
Note 🎁 Summarized by CodeRabbit FreeYour organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login. Comment |
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Summary
__tests__/scripts/preuninstall.test.ts— the only lifecycle script without test coverageContext
scripts/preuninstall.mjsalready implements hook removal from all three Claude Code settings scopes on package uninstall. This PR adds the missing test coverage to verify that behavior is correct.Test plan
bun run test:run— all 723 tests pass (14 new in this PR)~/.claude/settings.json🤖 Generated with Claude Code
Summary by CodeRabbit