Nw mutation test

From nWave-ai/nWave · View interactive version

Nw mutation test is an AI agent skill from the GitHub repository nWave-ai/nWave. Run an explicit mutation probe over a named production delta, or support the project-level nightly-delta policy. Disabled by default.

How to use this skill

Skill file

Mutation Test

Mutation testing is disabled by default. This skill runs only after an

explicit on-demand invocation or when the project itself declares

Mutation Testing Strategy: nightly-delta.

It is a standalone diagnostic outer loop, not a DELIVER phase, rigor knob, completion

gate, workflow state or substitute for semantic acceptance tests.

Input authority

mutation run.

filenames alone or the implementation agent's claims.

If the diff is empty, report not-applicable and stop. If a target is

missing, outside the repository or not production code, fail loudly before

starting a mutation tool.

Execution

  1. Detect the project's language and existing mutation runner. Do not impose a

Python-specific tool on another language.

  1. Prove the target's ordinary tests pass with the project's declared runner.
  2. Snapshot the user's worktree status.
  3. Create a dedicated disposable worktree or copy and run all mutations there.

Never mutate, reset or restore the user's worktree.

  1. Compare the user's status with the snapshot and discard only the disposable

target.

Each invocation binds the actual production delta/commit snapshot, ordinary-GREEN

baseline, oracle/support/source identities and native build/discovery graph.

Allocate distinct process, workspace, mutable config, build/temp/cache and result

paths with provenance; parallel probes cannot share fixed files or cache identity.

Tests must participate in that native graph, not a disconnected Python harness.

The repository's nightly Python adapter supports its declared Python/mutmut 3.8

contract only; it is not a cross-stack runner. Empty/unsupported target sets,

driver no-ops, zero generated mutants or interrupted attempts are never PASS100.

No supported runner is an honest indeterminate, not a fabricated PASS.

Result

The requested/project threshold (default 80%) applies only to a valid attributed

attempt with a measured nonzero denominator. Report actual generated, killed,

survived and incomplete/unclassified counts with their population and conservation.

Do not turn timeout, build/setup failure or untested mutants into killed outcomes,

or omit them to inflate the denominator. Preserve invalid attempt evidence and

partial actual counts without a passing rate.

file, line/symbol and smallest missing observable.

interruption, incomplete outcome or evidence not attributable to this delta.

Keep the interactive report concise: verdict, numerator/denominator, per-file

survivor count, and a bounded list of actionable survivors. Do not create a

per-delivery markdown report or another persistent progress artifact.

For nightly-delta, CI owns persistence: create or update one deduplicated

issue containing the same bounded report and the exact comparison range. A

later green run closes that issue. The nightly job must not expand to the

whole repository when its baseline is missing; establish a new baseline

explicitly instead.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.