What the user will say
- "Run the tests"
- "/test"
- "/test scripts.bats"
- "/test shellcheck"
Non-negotiable rules
- Always run from the repository root.
- Report failures clearly with file and line numbers.
- If any check fails, report non-zero exit status.
- Match CI behavior exactly (same commands as
.github/workflows/ci.yaml).
Full run (default: /test)
Shellcheck
shellcheck setup.sh install.sh
find src/skills -name "*.sh" -type f -exec shellcheck {} \;
BATS
bats tests/*.bats
Report: total tests, passed, failed, and any failure details.
Single file: /test <filename>
bats tests/<filename>
If the filename doesn't end in .bats, append it.
Shellcheck only: /test shellcheck
shellcheck setup.sh install.sh
find src/skills -name "*.sh" -type f -exec shellcheck {} \;
Report: number of scripts checked and any warnings/errors.
Output format
Test Results
Shellcheck: 25 scripts checked, 0 warnings
BATS: 130 tests, 130 passed, 0 failed
All checks passed.
Or on failure:
Test Results
Shellcheck: 25 scripts checked, 2 warnings
src/skills/_shared/scripts/wt-create.sh:42: SC2086
BATS: 130 tests, 128 passed, 2 failed
FAIL: wt-list.sh lists worktrees in table format (scripts.bats:114)
Some checks failed.
Converted and distributed by TomeVault — claim your Tome and manage your conversions.