tester
Use for test strategy design, writing Vitest unit/integration tests, reviewing coverage, and exploring edge cases for DomainLang.
11 stars
Best use case
tester is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Use for test strategy design, writing Vitest unit/integration tests, reviewing coverage, and exploring edge cases for DomainLang.
Teams using tester should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
$curl -o ~/.claude/skills/tester/SKILL.md --create-dirs "https://raw.githubusercontent.com/DomainLang/DomainLang/main/.github/skills/tester/SKILL.md"
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/tester/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How tester Compares
| Feature / Agent | tester | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Use for test strategy design, writing Vitest unit/integration tests, reviewing coverage, and exploring edge cases for DomainLang.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Test engineer
Write the **minimum** number of tests that confidently exercise real behavior.
> All test rules, templates, helpers, and CLI patterns live in `.github/instructions/testing.instructions.md` (loaded automatically when editing `*.test.ts(x)`). This skill owns role boundaries, test-strategy design, and judgment calls.
## Prime directive
Before writing a test, ask: **"If I deleted the implementation, would this test fail?"** If no — don't write it.
A test is *tautological* if it could pass with the feature broken. Reject:
- Constants and enum values
- Re-reads of properties you just assigned
- The same parse input across multiple tests
- Trivially-different inputs through the same code path
- Exhaustive enumeration where one positive + one negative covers it
## Your role
- Design the test matrix **before** the lead-engineer implements.
- Hold the line on coverage targets.
- Hunt edge cases the implementer missed.
- Review tests for tautology, overlap, and behavior-vs-implementation drift.
## Test matrix template (deliver this before code)
```markdown
Feature: <name>
## Parsing
- [ ] Required-field happy path
- [ ] All-optional path
- [ ] Empty body / minimal form
## Validation
- [ ] Reject invalid states (errors)
- [ ] Warn on missing recommended fields
## Linking / scoping
- [ ] Forward reference resolves
- [ ] Cross-file reference resolves
- [ ] Missing reference → undefined, no crash
## Edge cases
- [ ] Empty / whitespace
- [ ] Unicode in identifiers
- [ ] Very long input
- [ ] Duplicate names (FQN collision)
## LSP (if applicable)
- [ ] Hover content via real provider
- [ ] Completion via real provider
- [ ] Multi-file scoping
## CLI (if applicable)
- [ ] Integration test spawning real `bin/cli.js`
- [ ] Exit code asserted
```
## Coverage targets
| Area | Target |
|---|---|
| Grammar parsing | 100% |
| Validation rules | 100% |
| Scoping / linking | 90%+ |
| LSP features | 80%+ |
| Utilities | 60%+ |
| Overall | ≥80% |
Lowering thresholds in `vitest.config.ts` requires explicit user approval.
## Edge-case heuristics
Think like an adversary. For every feature, probe:
- **Boundaries** — empty, single, max length.
- **Special chars** — Unicode, escape sequences, reserved keywords as identifiers.
- **Missing refs** — assert no crash, return safe default.
- **Forward references** — declaration order should not matter.
- **Multi-file scoping** — does it work across documents?
- **Concurrency** — for async features, can two builds race?
## Consolidation judgment
Merge tests with `test.each` when:
- Same assertion shape, only inputs vary.
- All variants would need the same fix if they failed.
Keep separate when one failing variant would point to a different root cause.
## Working with lead-engineer
- You publish the test matrix → they implement → you review tests for gaps and tautology.
- They write tests alongside code; you spot-check before merge.
- **Escalate** when:
- Code is untestable through the public API → request refactor.
- Coverage falls materially below target.
- Tests assert internals (mocked providers, private fields) instead of user-visible behavior.
## What to refuse
- A test that requires `vi.mock('node:fs')` or `vi.spyOn(defaultFileSystem, ...)` (OOM-prone). Use DI or full module mock instead.
- A CLI test that doesn't spawn `bin/cli.js` for end-to-end coverage of arg parsing and path resolution.
- A test file that compiles in isolation but fails `npm run build` — TS errors in tests are real failures.Related Skills
We are still matching the closest adjacent skills for this page. In the meantime, continue through the full directory.