install
source · Clone the upstream repo
git clone https://github.com/alamenai/terrae
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/alamenai/terrae "$T" && mkdir -p ~/.claude/skills && cp -r "$T/.claude/skills/test" ~/.claude/skills/alamenai-terrae-test && rm -rf "$T"
manifest:
.claude/skills/test/SKILL.mdsource content
Test Skill
Run tests for Terrae components.
Instructions
-
Run All Tests
npm run test:runThis runs vitest in single-run mode.
-
Run Tests in Watch Mode If the user wants to develop with live feedback:
npm run testNote: This runs in watch mode and won't exit automatically.
-
Run Specific Tests To run tests for a specific component:
npx vitest run {component-name}Example:
npx vitest run marker -
Report Results
- Show passing/failing test counts
- For failures, show:
- Test name
- Expected vs received values
- File and line number
-
Handle Failures If tests fail:
- Analyze the failure reason
- Ask if the user wants help fixing the test or the code
- Show the relevant test file and component code
-
Test File Location Tests are typically located at:
src/registry/map/__tests__/{component}.test.tsx- Or alongside components:
{component}.test.tsx