
Property based testing
Lets your agent write, review and debug property-based tests across languages
Property based testing 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
- 8.6K
- Last commit
- License
- CC-BY-SA-4.0
- Listing updated
Similar skills
About Property based testing
This skill guides an agent through property-based testing, where a rule is asserted over a whole input domain and a generator searches for counterexamples instead of checking a fixed list of examples. It covers choosing properties such as roundtrips, inverses, oracles, idempotence and invariants, and ranks them so the agent aims for the strongest property the code supports.
The guidance also covers the common ways property tests end up checking nothing, including tautological assertions that restate the implementation and vacuous assume() filters, and it steers the agent toward putting constraints into strategies. When code has no clear property yet, the skill suggests refactorings that expose one, such as extracting a pure core or returning values instead of mutating state. It also helps triage a failing property by separating a wrong property from a genuine bug.
The skill ships reference files for generator design, reviewing existing suites, interpreting failures and selecting libraries, including Echidna and Medusa for Solidity invariants. It has no scripts. Work is done in the project's own test framework, and the skill asks before adding a new PBT dependency to a project that lacks one.
When your agent uses it
Writes, reviews, and debugs property-based tests — Hypothesis, fast-check, proptest, jqwik, rapid, and Echidna or Medusa for Solidity invariants. Use whenever tests should cover a whole input domain instead of a hand-picked list of examples: encode/decode and serialize/deserialize pairs, parsers, canonicalizers and normalizers, validators, numeric and Decimal types, comparators and sort order, data structures, and smart-contract state invariants. Also use when adding cases to an existing @given, fast-check, or proptest suite, when judging whether existing property tests assert anything real, and when a generator has shrunk a counterexample and you need to tell a wrong property from a genuine bug. Not for coverage-guided binary fuzzing (libFuzzer, AFL), mutation-testing campaigns, static analysis, benchmarking, or end-to-end UI tests.
From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.
What it can access
- Instructions only, no scripts(see the files on GitHub)
- License: CC-BY-SA-4.0(see the files on GitHub)
From a static check of its 9 files (39 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 property-based-testing plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):
/plugin marketplace add trailofbits/skills
/plugin install property-based-testing@trailofbitsOr copy only this skill to ~/.claude/skills/property-based-testing:
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/trailofbits/skills.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/property-based-testing &&
cp -R "$tmp/plugins/property-based-testing/skills/property-based-testing" ~/.claude/skills/property-based-testing &&
rm -rf "$tmp"For one project only, put the folder in .claude/skills/property-based-testing inside it instead.
Copy the skill folder to ~/.agents/skills/property-based-testing to use it in every repository:
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/trailofbits/skills.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/property-based-testing &&
cp -R "$tmp/plugins/property-based-testing/skills/property-based-testing" ~/.agents/skills/property-based-testing &&
rm -rf "$tmp"For one repository only, put the folder in .agents/skills/property-based-testing inside it instead.
Copy the skill folder to ~/.cursor/skills/property-based-testing to use it in every project:
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/trailofbits/skills.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/property-based-testing &&
cp -R "$tmp/plugins/property-based-testing/skills/property-based-testing" ~/.cursor/skills/property-based-testing &&
rm -rf "$tmp"For one project only, put the folder in .cursor/skills/property-based-testing inside it instead.
Run in a terminal (add --scope workspace to install it for the current workspace only):
gemini skills install https://github.com/trailofbits/skills.git --path plugins/property-based-testing/skills/property-based-testingOr copy the folder to ~/.gemini/skills/property-based-testing yourself.
For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/property-based-testing:
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/trailofbits/skills.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/property-based-testing &&
cp -R "$tmp/plugins/property-based-testing/skills/property-based-testing" ~/.copilot/skills/property-based-testing &&
rm -rf "$tmp"For one project only, put the folder in .github/skills/property-based-testing inside it instead.
Get the folder:
git clone --depth 1 https://github.com/trailofbits/skills.gitThen copy skills/plugins/property-based-testing/skills/property-based-testing into your agent's skills folder as property-based-testing. Agents that support SKILL.md read one folder per skill.
What it does
- Property selection guidance
- Helps choose roundtrip, inverse, oracle, idempotence or invariant properties that fit the code under test.
- Test quality review
- Flags tautological assertions and vacuous assume() filters in existing property tests.
- Strategy design
- Pushes input constraints into generators so tests produce valid inputs directly rather than filtering them.
- Refactoring for testability
- Suggests rearrangements, such as extracting a pure core, that expose a property in impure code.
- Failure triage
- Separates a wrong property from an ambiguous specification or a real bug after a counterexample shrinks.
- Smart contract invariants
- Covers Echidna and Medusa for asserting state invariants in Solidity contracts.
Good for
- Write property tests for an encode and decode pair
- Review whether existing Hypothesis tests assert anything meaningful
- Turn a hand-picked example suite into a property-based one
- Work out whether a shrunk counterexample is a bug or a wrong property
- Write Echidna invariants for a Solidity contract's state
Property based testing FAQ
What does the skill need from my project?
It works with the project's own test framework and does not require a new dependency. If the project lacks a PBT library, the skill offers to add one and leaves the decision to you.
Which libraries does Property based testing cover?
Hypothesis, fast-check, proptest, jqwik, rapid, and Echidna or Medusa for Solidity invariants.
When does Property based testing trigger?
When tests should cover a whole input domain, when adding cases to an existing property suite, when judging existing property tests, or when a generator has shrunk a counterexample.
Does Property based testing cover coverage-guided fuzzing?
No. Binary fuzzing with libFuzzer or AFL, mutation testing, static analysis, benchmarking and end-to-end UI tests are out of scope.
How do I install Property based testing in Claude Code?
Copy the skill folder from GitHub to ~/.claude/skills/property-based-testing to use it in all your projects, or to .claude/skills/property-based-testing in one project. Or install the property-based-testing plugin, which includes it: /plugin marketplace add trailofbits/skills, then /plugin install property-based-testing@trailofbits.
Does Property based testing 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 Property based testing?
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 Property based testing?
The closest alternatives to Property based testing are Principle test behavior not implementation, Testing strategy, TDD, Create formal verification skill and Unittest skill.
Where this comes from
- Description: from the skill's own SKILL.md.
More from trailofbits/skills

Lets an agent measure timing side channels in running crypto code with dudect and Timecop
- Open source
- 8.6K GitHub stars
- Security

Generates Claude Code security testing skills from the Trail of Bits Testing Handbook
- Open source
- 8.6K GitHub stars
- Security

Guides mewt or muton mutation testing runs and triages surviving mutants
- Open source
- 8.6K GitHub stars
- Developer tools

Audits GitHub Actions workflows that run AI coding agents for prompt injection risks
- Open source
- 8.6K GitHub stars
- AI models and LLM tooling

Builds a verified map of an unfamiliar codebase before any bug hunting begins
- Open source
- 8.6K GitHub stars
- Security

Audits Algorand TEAL and PyTeal contracts against 11 platform-specific vulnerability
- Open source
- 8.6K GitHub stars
- Security




