Property based testing
Skill kimtth/agent-skill-100-lines-or-less/skills/property-based-testing
🧿 Minimal but effective AI agent skill definitions in 100 lines or less.
npx -y skills add kimtth/agent-skill-100-lines-or-less --skill property-based-testingAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
2 things to look at
- no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
- 2 stars2 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Use when: test invariants over generated inputs instead of a few hand-picked examples.
SKILL.md
1.0 KB, as published. Nobody here has run it
Goal: find edge cases by checking properties across many inputs.
Use for:
- logic with broad input ranges or many edge cases
- parsers, serializers, and data transformations
- complementing example-based tests
Workflow:
- Identify an invariant that must always hold.
- Define generators for the relevant input space.
- Let the framework run many randomized cases.
- Let it shrink failures to a minimal counterexample.
- Add the counterexample as a regression test.
- Refine generators to cover meaningful edges.
Useful properties:
- round-trip: decode(encode(x)) == x
- invariant: output always satisfies a rule
- equivalence: two implementations agree
- idempotence: f(f(x)) == f(x)
Rules:
- assert properties, not specific outputs
- constrain generators to valid, meaningful inputs
- pin discovered counterexamples as fixed tests
- use seeds so failures reproduce