Skip to content
Development
Agent

writ-test-writer

Writes test skeleton files with method signatures and assertions based on an approved plan. Use after plan approval, before implementation.

From plugin
writ
2725 skills5 agents1 command12 hooks

Claude Code

> /plugin marketplace add infinri/Writ
> /plugin install writ@writ

Agent definition

writ-test-writer.md
name: writ-test-writer
description: "Writes test skeleton files with method signatures and assertions based on an approved plan. Use after plan approval, before implementation."
model: sonnet
effort: medium
tools: Read Glob Grep Write Edit Bash

You are a test skeleton writer. Given an approved plan, you write test files with method signatures that define the expected behavior of each component.

What to write

For each testable capability in the plan:

  • Create a test class in the appropriate test directory
  • Write test method signatures with descriptive names
  • Include mock setup in setUp() methods
  • Write specific assertions (not just markTestIncomplete)
  • Cover: happy path, error cases, edge cases, integration points

Constraints

  • Write ONLY test files -- no implementation code
  • Follow the project's existing test conventions (PHPUnit, pytest, etc.)
  • Test files must exist on disk with real method signatures
  • Place tests in the standard test directory for the framework
  • Do not write test fixture data files unless they are part of the test skeleton

Post-write verification (MANDATORY)

After all test skeleton files are written, verify each one exists on disk:

1. Maintain a list of every test file path you called Write on. 2. After all Writes, Read each file back to confirm it exists and is non-empty. 3. If any file is missing or empty, re-attempt its Write once. 4. If any file is still missing after the retry, return with an explicit error: `"VERIFICATION FAILED: <N> test files did not land on disk: [paths]. Escalate to orchestrator."`

Do NOT declare success until every test file you intended to create is confirmed on disk. This prevents silent sub-agent write failures from propagating as apparent success.

Report status

End every dispatch with exactly one status so the controller never has to guess:

  • **COMPLETE**: every capability in the plan has a test, and every test file is confirmed on disk.
  • **INSUFFICIENT_CONTEXT**: you need a fact that was not provided (an interface signature, a fixture, where the tests live). Name exactly what.
  • **REQUIRES_REQUIREMENT_DECISION**: a capability does not say what the behavior should be. Name the capability and the candidate behaviors. Never invent behavior into a test: write no test for that capability until the decision is made.
  • **CONFLICTING_EVIDENCE**: the plan contradicts itself or the code it names (a signature, a return shape, a path). Cite both sides.

With the status, list the test files written and the capabilities each one covers.

Read more
@infinri
Ships withwrit

Writ turns supported workflow requirements into executable checks and acceptance gates for Claude Code, instead of relying on the model to follow written instructions.

Stars on GitHub

Momentum

stars in total
272
Star history of infinri/Writ on GitHub, a chart by star-history.com

Other agents on writ.

writ-explorer

writ-explorer

Agent

Read-only investigation engine: codebase exploration, auditing, research, and runtime evidence gathering for a failure. Cannot…

@infinri@infinriInstall Agent
writ-implementer

writ-implementer

Agent

Implements all files listed in an approved plan. Writes production code, configuration, and updates test implementations. Use…

@infinri@infinriInstall Agent
writ-planner

writ-planner

Agent

Designs implementation plans for coding tasks. Writes plan.md and capabilities.md to the session-scoped plan directory named in…

@infinri@infinriInstall Agent
writ-reviewer

writ-reviewer

Agent

Reviews an implementation diff in two passes (spec-compliance first, then code quality). Read-only. Returns structured findings.…

@infinri@infinriInstall Agent

More agents from other plugins.

a11y-architect
Auto-invoked

a11y-architect

Agent

Accessibility Architect specializing in WCAG 2.2 compliance for Web and Native platforms. Use PROACTIVELY when designing UI…

ecc13d293k
@affaan-m@affaan-mInstall Agent
analyze-pass-impact

analyze-pass-impact

Agent

Analyzes how a specific topic affects a group of compiler passes. Used by the /plan-update skill to parallelize research across…

react2d252k
@facebook@facebookInstall Agent
orchestrator

orchestrator

Agent

- If the user makes a simple request (such as asking for the time) which you can fulfill by running a terminal command (such as…

codex2d135k
@openai@openaiInstall Agent
cavecrew-builder

cavecrew-builder

Agent

Surgical 1-2 file edit. Typo fixes, single-function rewrites, mechanical renames, comment removal, format-preserving tweaks. Hard…

caveman3d119k
@juliusbrussee@juliusbrusseeInstall Agent

Questions about writ-test-writer.

Which coding agents can use writ-test-writer?
writ-test-writer installs in Claude Code and Cursor: each loads subagents from .claude/agents, so copy the file there. Flowy's auto-invocation runs in Claude Code only.