audit-tests
SkillDev toolsLets your agent check that permission-gated React components have unit tests and write any that are missing.
Then ask your AI: use the audit-tests skill
Details
Instructions available. Your AI can read the instructions. Execution depends on the setup they require.
Account requirements not reviewed. Check the skill instructions before use; Ahel provides instructions and does not run this skill.
No other account needed.
Add it as a step in a pipeline you build on Ahel, or connect Ahel to Claude, ChatGPT, Cursor, Claude Code or Codex and ask your AI to use it.
About this skill
Audit & fix unit tests for permission-gated components
What this skill tells your AI
The instructions your AI receives, as published by trycompai/comp in .agents/skills/audit-tests/SKILL.md and read by Ahel’s review.
Check that unit tests exist and pass for permission-gated components. Write missing tests immediately.
Infrastructure
- Framework: Vitest with jsdom
- Component testing:
@testing-library/react+@testing-library/jest-dom - Setup:
apps/app/src/test-utils/setup.ts - Permission mocks:
apps/app/src/test-utils/mocks/permissions.ts - Run:
cd apps/app && bunx vitest run
Required Test Pattern
Every component importing usePermissions MUST have tests covering:
- Admin (write) user: mutation elements visible/enabled
- Auditor (read-only): mutation elements hidden/disabled
- Data always visible: read-only content renders regardless of permissions
Use setMockPermissions, ADMIN_PERMISSIONS, AUDITOR_PERMISSIONS from test utils.
Process
- Find components with
usePermissionsin$ARGUMENTS - Check for corresponding
.test.tsxfiles - Write missing tests following the pattern above
- Fix any failing tests
- Run:
cd apps/app && bunx vitest run
Signals
- GitHub stars
- 2k
- Forks
- 424
- Last commit
- Oct 2026
Advanced
- Item type
- skill
- Key
audit-tests-trycompai- Source
- github.com/trycompai/comp
Related picks
Skill · mattpocock
The pick for TypeScripttypescript-providers
Skill · composiohq
The pick for TypeScriptreact-component-performance
Skill · davila7
The pick for Reactreact-doctor
Skill · millionco
The pick for Reactteach
Skill · mattpocock
More in Dev toolscaveman
Skill · juliusbrussee
More in Dev tools