Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add Kevin-Liu-01/Agent-Machines --skill test-writinggit clone --depth 1 https://github.com/Kevin-Liu-01/Agent-MachinesWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/kevin-liu-01/agent-machines/test-writing)<a href="https://agentmods.dev/skills/kevin-liu-01/agent-machines/test-writing"><img src="https://agentmods.dev/badge/skills/kevin-liu-01/agent-machines/test-writing/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/kevin-liu-01/agent-machines/test-writing"><img src="https://agentmods.dev/badge/skills/kevin-liu-01/agent-machines/test-writing.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00058 | $0.01021 |
| Opus 5 | $0.00029 | $0.00511 |
| Sonnet 5 | $0.00012 | $0.00204 |
| Haiku 4.5 | $0.00006 | $0.00102 |
Grade A, and why
test-writing scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 126 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Test Writing
Output philosophy
Tests communicate two things: what passed and what failed. Everything
else is noise. Model output on prove, go test, and Plan 9's
/bin/test -- not JUnit XML rendered as prose.
The ok / FAIL convention
Every assertion or logical group prints exactly one line:
ok mkdir
ok rename
ok link (nlink=2)
FAIL symlink (expected target 'foo', got 'bar')
Rules:
okis lowercase, left-aligned to 6 chars (ok).FAILis uppercase, left-aligned to 6 chars (FAIL).skipfor precondition-gated tests (skip fuse (no /dev/fuse)).- After the tag: a terse noun phrase, not a sentence.
- Parenthetical detail only when the assertion carries a value
(
nlink=2,pid 4821). - Summary line at the end:
7/7 posix sanity okor6/7 posix sanity FAIL.
Rust #[test]
Rust test output is managed by cargo test (or nextest). The
convention is in the test name, not in println!:
#[test]
fn invariant_rename_over_non_empty_dir_returns_enotempty() {
// ...
assert_eq!(err, Error::DirectoryNotEmpty);
}
Custom assertion helpers should panic with terse messages:
fn assert_nlink(store: &MetadataStore, ino: Ino, expected: u32) {
let attr = store.get_inode(ino).unwrap().unwrap();
assert_eq!(attr.nlink, expected, "ino {ino:?} nlink");
}
Go testing.T
func TestInvariant_ReconcilerSurvivesPerWorkspaceError(t *testing.T) {
// ...
if got != want {
t.Fatalf("workspace B status: got %v, want %v", got, want)
}
}
Use t.Fatalf (not t.Errorf + t.FailNow). One call, one line.
Python pytest
Let pytest handle reporting. Assertions use bare assert:
def test_invariant_chunk_key_is_deterministic():
a = chunk_key("ws-1", b"hello")
b = chunk_key("ws-1", b"hello")
assert a == b
For parametrized output, use pytest.mark.parametrize -- it
generates one ok line per case automatically.
CI integration
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 8d ago First seen · 126 lines · 58 tokens per session scan A fe68e474b748
test-writing is a skill published in the GitHub repository Kevin-Liu-01/Agent-Machines (29 stars, last pushed yesterday), licensed MIT. It adds 58 tokens to every session and 1,021 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
api-testing
Testing patterns for MCP tool/resource handlers using createMockContext and Vitest. Covers mock context options, handler testing, McpError assertions, format testing, Vitest config setup, and test isolation conventions.
add-test
Scaffold a test file for an existing tool, resource, or service. Use when the user asks to add tests, improve coverage, or when a definition exists without a matching test file.
email-formatting
Markdown formatting conventions for email summary documents — heading depth, list style, line length, emoji policy, and a mandatory provenance footer. Read this when producing a markdown report that summarizes one or more email messages so the output matches the project's house style.
dogfood
This skill guides you through systematic exploratory QA testing of web applications using the browser toolset. You will navigate the application, interact with elements, capture evidence of issues, and produce a structured bug report.
holix-cron
Schedule recurring agent tasks via Holix built-in gateway cron (not crontab or custom scripts).
blazemeter-api-reference
Comprehensive reference for BlazeMeter REST APIs, including authentication, identifiers, and API endpoints. Use when working with BlazeMeter APIs for (1) Understanding BlazeMeter REST API structure, (2) Authenticating API requests, (3) Obtaining identifiers (Workspace ID, Project ID, Test ID, etc.), (4) Using Test…