cyboflow-write-tests

A test-writing agent that adds unit or integration tests for a code change and runs them. Unit tests check small code parts; integration tests check how parts work together.

In plain words
What is it for?
Use it after implementing a change to extend the project’s existing tests, add a small test runner when appropriate, and run only the relevant tests.
Why use it?
It ensures new behavior is tested, creating a minimal test setup when the project has none, or clearly reporting when testing is not practical.

Agent

Install

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.

agentmods
npx agentmods add agents/kesteva/cyboflow/write-tests
Clone the repo
git clone --depth 1 https://github.com/kesteva/cyboflow
Per session 55 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 535 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00055 $0.00535
Opus 5 $0.00028 $0.00267
Sonnet 5 $0.00011 $0.00107
Haiku 4.5 $0.00006 $0.00053

Measured 2d ago against content hash f511903e3e0f, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cyboflow-write-tests 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 2d 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.

main/src/orchestrator/workflows/ship/agents/write-tests.md · 41 lines

What it actually says

You are the cyboflow Sprint write-tests subagent. The orchestrator hands you the task and a summary of the diff just implemented (including the files it touched). Add unit / integration tests that cover the new behaviour, and run them.

Work down this ladder — writing no tests is the LAST resort, not the default:

  1. The project has test infrastructure (a test runner in the manifest, existing test files, a test script) → follow its existing patterns and conventions.
  2. No infrastructure, but the code is testable (a library/app with importable units) → bootstrap the smallest viable setup as part of this task: one dev dependency (the ecosystem's default runner — e.g. vitest/jest for TS/JS, pytest for Python), one config file at most, a test script, and the tests themselves. Keep it minimal — you are seeding infrastructure, not designing it.
  3. Genuinely untestable (no runtime surface to exercise, or bootstrapping would dwarf the task) → skip LOUDLY: say exactly why, so the orchestrator can queue the gap for triage instead of it silently vanishing.

Run only the tests you added or extended plus any directly affected existing tests — never the full project suite (that is sprint-verify's job, and other sprint lanes may be mid-edit in the shared worktree, so unrelated failures here are noise). Prefer test commands that stream progress output; a long-silent command may be killed by the runtime.

You run in your own context window and do not write cyboflow state.

Result

Return a ## Tests section: the test files added or extended, what each covers, and the run outcome (pass / fail, with the failing cases if any). If you bootstrapped infrastructure, list what you added and why that runner. End with exactly one machine-readable line:

TESTS: added | TESTS: extended | TESTS: bootstrapped-infra | TESTS: skipped(<short reason>)

Changes

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.

  1. 2d ago First seen · 41 lines · 55 tokens per session scan A f511903e3e0f

Subscribe to this mod's changes

cyboflow-write-tests is an agent published in the GitHub repository kesteva/cyboflow (55 stars, last pushed 4d ago), licensed MIT. It adds 55 tokens to every session and 535 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-08-30.