add-tests
Skill12 starsChanged 8 months agoMITView on GitHub
Author Unity EditMode, PlayMode, or regression tests for the current change without conflating that with test execution.
6 other projects use a version of this.
Adopted by
Most recently taken up by
- buildomator/buildomatortheir own version, first seen Nov 4, 2026
- ypxing/coding-crewtheir own version, first seen Oct 13, 2026
- royalpinto007/ship-skillstheir own version, first seen Oct 13, 2026
- owid/owid-graphertheir own version, first seen Oct 8, 2026
- dperezcabrera/pico-skillstheir own version, first seen Jul 29, 2026
- davidmeirlevy/obvious-skillstheir own version, first seen Jul 5, 2026
Other versions6 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 6
- owid/owid-grapher★ 1.6ksame name
- buildomator/buildomator★ 102same name
- davidmeirlevy/obvious-skills★ 6same name
- dperezcabrera/pico-skills★ 4same name
- royalpinto007/ship-skills★ 1same name
- ypxing/coding-crew★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository29 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- best-practiceSkill
- bootstrapSkill
- briefSkill
- changesSkill
- claude-code-reviewSkill
- claude-plan-reviewSkill
- codex-code-reviewSkill
- codex-plan-reviewSkill
- commit-pushSkill
- depsSkill
- design-researchSkill
- designSkill
- doc-driftSkill
- doc-syncSkill
- doc-tidySkill
- executeSkill
- explainSkill
- full-briefSkill
- goSkill
- grandmaSkill
- planSkill
- post-design-reviewSkill
- recordSkill
- self-reviewSkill
- tech-researchSkill
- testSkill
- timelineSkill
The file
We split this skill into the rules it gives an agent
6 rules. 0 are common, 4 are distinctive, and 2 are very specific to this project.
0
Common
Most of the 4 edited versions we read keep these.
4
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 9
Add or update Unity tests for the current change.
- Distinctive: line 44
Ask the user one concise question if the target is still ambiguous
- Distinctive: line 63
add the highest-risk edge case or regression assertion
- Distinctive: line 64
avoid tests that merely duplicate production implementation line by line
- Distinctive: line 77
If the expected behavior is ambiguous, ask one short question before writing more code
- Very specific: line 79
--automode: after writing the tests, run qq-execute-checkpoint.py pipeline-advance --project .
“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Run qq scripts as
${CLAUDE_PLUGIN_ROOT}/bin/<name>: they are not on PATH, so a bareqq-project-state.pyexits 127.
Respond in the user's preferred language (detect from their recent messages, or fall back to the language setting in CLAUDE.md).
Add or update Unity tests for the current change. This skill is for writing tests, not for running them. After authoring coverage, hand off to /qq:test.
Before deciding what to assert (component layouts, serialized values, runtime state), read the actual values from the live Editor instead of guessing from source, read-only, through the project's channel:
${CLAUDE_PLUGIN_ROOT}/bin/qq-unity-cli.py channel --project "$PWD"printsunity-cli,tykitornone(shared/unity-live-state.md).
- Official Unity CLI:
unity command --project-path "$PWD" --json --no-banner find_gameobjects -- --name X, thenget_component_properties -- --target <instanceId> --type Fooorget_serialized_fields(shared/unity-cli-reference.md).- tykit:
unity_query,unity_object,get-field,get-array(shared/tykit-reference.md).- Neither: derive the expected values from source and say they are unverified.
Arguments: $ARGUMENTS
- A file path, symbol, bug description, or plan step that needs coverage
editmode/edit: force EditMode coverageplaymode/play: force PlayMode coverageregression: force the smallest regression-focused test--assembly "Asm.Tests": prefer a specific test assembly--auto: skip prompts and continue into/qq:test --autoafter tests are written
With --auto, first make sure a pipeline tracks this run, so the handoff at the end can advance it: qq-execute-checkpoint.py pipeline-start --project . --type feature --current-skill "/qq:add-tests" --branch "$(git branch --show-current)" --if-not-running. It starts one only when none is running here (you were invoked on your own) and leaves a running one alone.
0. Read qq project state first when available
${CLAUDE_PLUGIN_ROOT}/bin/qq-project-state.py --prettywork_modeandpolicy_profile: expected verification pressurechanged_runtime_files: the code under test when the user did not specify a targetlast_test_status: whether coverage is missing vs. failing
1. Determine the target
Pick scope in this order:
- Explicit user input (file path, bug description, plan step, or test type)
- A known failing bug / regression path from the current conversation
- The active implementation plan step and its done criteria; if the plan has a Tests step, implement that step
- Current uncommitted runtime changes
- Ask the user one concise question if the target is still ambiguous
Narrow broad input: one system over the whole feature, one regression path over a full suite rewrite, one test assembly over new scattered files.
2. Fit the existing test layout
Read the existing tests and test .asmdef files near the code under test, reuse their helpers, fixtures, scene setup and naming, and prefer extending an existing test file. If no tests exist yet, use Assets/Tests/EditMode/ for pure logic or editor-side behavior and Assets/Tests/PlayMode/ for scene/lifecycle/integration behavior.
3. Choose the right test kind
Unless the user forced a mode, choose the lightest one that still proves the behavior:
- EditMode: pure logic, data transforms, orchestration, deterministic calculations — anything that needs no scene frames
- PlayMode: MonoBehaviour lifecycle, scene wiring, frame progression, physics, animation
- Regression: the smallest test that proves a bug stays fixed; prefer this for
fixmode when feasible
4. Write the tests
- cover the intended behavior, not every branch in the file
- add the highest-risk edge case or regression assertion
- avoid tests that merely duplicate production implementation line by line
- take expected values from an independent source: hand-calculated literals, worked examples in the design, or real-world data, never the same formula, code path, or config the code under test uses
- where it matters, check both directions: the thing happens when it should, and does not when it should not
- for values designers will keep tuning, assert relations (greater than, monotonic, conserved) instead of literals; keep independent literals for rules that should not change
- name the bug each test catches: a one-line change to the code under test that would make it fail. If you cannot name one, the test checks nothing
For a bug fix, write the regression first when the repro is clear; if the architecture makes the repro impossible to express cleanly, say so and write the next-best narrow guardrail.
5. Stop at authored coverage
- Summarize which files changed and which behavior is now covered
- Recommend the exact
/qq:testcommand to run next, usingeditmode,playmode,--assembly, or--filterwhen that would keep validation narrow - For a test guarding a bug fix or a high-risk rule, also suggest proving it can fail: apply that one-line change, confirm the test fails, then revert it
- If the expected behavior is ambiguous, ask one short question before writing more code
--auto mode: after writing the tests, run qq-execute-checkpoint.py pipeline-advance --project . --completed-skill "/qq:add-tests" --next-skill "/qq:test", then invoke /qq:test --auto with the narrowest appropriate scope.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

