Skip to content
Skill

Test

Writes failing tests from approved acceptance criteria before any implementation exists

Test is an open-source agent skill for developer tools. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

Scripts
None
Platforms
Claude Code, Codex, Cursor
GitHub stars
19
Last commit
License
Apache-2.0
Listing updated

Similar skills

About Test

This skill guides the agent through a test-first step in the mokata workflow. It starts by retrieving a saved spec with its acceptance criteria, and it stops and asks for a spec if none is persisted. The agent then writes one test per criterion, checks that each test fails before any implementation is written, and keeps tests tied to real function names and signatures rather than invented interfaces.

The instructions also push for coverage at the point where a value is read by a caller, not just where it is produced, and for inputs at the edges of each criterion's domain such as empty, falsy, absent and hostile values. It asks the agent to record each test run with mokata progress commands and to flag any criterion that is wrong or untestable so the spec can be amended instead of silently changing coverage.

The skill is a single SKILL.md with no bundled scripts. It relies on mokata's spec and code-graph commands, and it is meant for Python projects in the mokata repository.

When your agent uses it

mokata · Write failing tests first (RED); no implementation.

From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.

What it can access

From a static check of its 1 file (12 KB) on GitHub on 1 December 2026. Nothing was run. Read the files before you install a skill: it can tell your agent to run anything its tools allow.

Check another skill before you install it.

Install

This skill ships in the mokata plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

/plugin marketplace add JasGujral/mokata-oss
/plugin install mokata@mostack

Or copy only this skill to ~/.claude/skills/test:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/JasGujral/mokata-oss.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/test &&
cp -R "$tmp/src/mokata/skills/test" ~/.claude/skills/test &&
rm -rf "$tmp"

For one project only, put the folder in .claude/skills/test inside it instead.

Claude Code docs on skills

Copy the skill folder to ~/.agents/skills/test to use it in every repository:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/JasGujral/mokata-oss.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/test &&
cp -R "$tmp/src/mokata/skills/test" ~/.agents/skills/test &&
rm -rf "$tmp"

For one repository only, put the folder in .agents/skills/test inside it instead.

Codex docs on skills

Copy the skill folder to ~/.cursor/skills/test to use it in every project:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/JasGujral/mokata-oss.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/test &&
cp -R "$tmp/src/mokata/skills/test" ~/.cursor/skills/test &&
rm -rf "$tmp"

For one project only, put the folder in .cursor/skills/test inside it instead.

Cursor docs on skills

Run in a terminal (add --scope workspace to install it for the current workspace only):

gemini skills install https://github.com/JasGujral/mokata-oss.git --path src/mokata/skills/test

Or copy the folder to ~/.gemini/skills/test yourself.

Gemini CLI docs on skills

For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/test:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/JasGujral/mokata-oss.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/test &&
cp -R "$tmp/src/mokata/skills/test" ~/.copilot/skills/test &&
rm -rf "$tmp"

For one project only, put the folder in .github/skills/test inside it instead.

VS Code docs on skills

Get the folder:

git clone --depth 1 https://github.com/JasGujral/mokata-oss.git

Then copy mokata-oss/src/mokata/skills/test into your agent's skills folder as test. Agents that support SKILL.md read one folder per skill.

The SKILL.md format

What it does

Spec-gated test writing
Requires a persisted spec with acceptance criteria before any tests are written.
Red-first verification
Expects each test to be seen failing before implementation code exists.
Consumer-level assertions
Checks criteria where the value is read by callers, not only where it is produced.
Boundary input coverage
Feeds empty, falsy, absent and hostile values for each acceptance criterion.
Run progress recording
Logs each test run by full node id through mokata progress commands.

Good for

  • Write failing tests for the acceptance criteria of an approved spec
  • Add tests for a feature before any implementation is started
  • Check that a function's return value is covered at the point a caller reads it
  • Identify edge-case inputs that a spec's acceptance criteria should be tested against

Test FAQ

What does Test need before it runs?

It needs a saved spec with at least one acceptance criterion, retrieved with the spec_show tool or mokata spec show. If none exists, the skill tells the agent to produce the spec first.

Does Test write implementation code?

No. The skill forbids writing implementation in this step and expects the tests to fail first. Implementation belongs to the separate develop step.

When does Test trigger?

It is meant to engage when a spec's acceptance criteria need failing tests, when the user asks for tests on approved behaviour, or when starting test-driven development before implementation exists.

Which AI clients does Test support?

The listing does not tie it to specific clients, so it follows the shared agent skills format and is listed for all supported clients.

How do I install Test in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/test to use it in all your projects, or to .claude/skills/test in one project. Or install the mokata plugin, which includes it: /plugin marketplace add JasGujral/mokata-oss, then /plugin install mokata@mostack.

Does Test run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

Which AI agents can use Test?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

What are the best alternatives to Test?

The closest alternatives to Test are Develop, Spec, Mt spec, TDD and Testing.

Where this comes from

  • Description: from the skill's own SKILL.md.

More from JasGujral/mokata-oss

  1. Makes the agent design API contracts first and check callers before changing them

    • Open source
    • 19 GitHub stars
    • Developer tools
  2. Gives an agent NestJS rules for guards, DTO validation, modules and tests

    • Open source
    • 19 GitHub stars
    • Developer tools
  3. Guides an agent through Socratic exploration of an approach before any spec or code

    • Open source
    • 19 GitHub stars
    • Developer tools
  4. Guides an agent to capture live browser console, network and page state for tests

    • Open source
    • 19 GitHub stars
    • Developer tools
  5. Guides the agent to reproduce a reported bug with a failing test before fixing it

    • Open source
    • 19 GitHub stars
    • Developer tools
  6. Guides an agent on CI/CD pipelines, release builds and pinned supply-chain posture

    • Open source
    • 19 GitHub stars
    • Developer tools