Skip to content

Instantly share code, notes, and snippets.

@npryce
Last active September 18, 2025 20:18
Show Gist options
  • Select an option

  • Save npryce/4147916 to your computer and use it in GitHub Desktop.

Select an option

Save npryce/4147916 to your computer and use it in GitHub Desktop.
Property-Based Testing Tools

If you're coming to the Property-Based TDD As If You Meant It Workshop, you will need to bring a laptop with your favourite programming environment, a property-based testing library and, depending on the language, a test framework to run the property-based-tests.

Any other languages or suggestions? Comment below.

.NET (C#, F#, VB)

Python:

  • Factcheck -- requires a test framework (I like pytest), I wrote it (benefits - you can ask me about it, drawbacks - it's not very mature). Can be installed from PyPI with Pip or easy_install.
  • Hypothesis -- requires a test framework, provides decorators for easy integration
  • pytest-quickcheck - requires pytest, I found it hard to extend, and so wrote Factcheck

Ruby:

Scala:

Clojure:

Java:

Groovy:

  • Gruesome -- a quick and dirty implementation for Groovy

JavaScript:

@scarytom

Copy link
Copy Markdown

For a Clojure project with the correct clojurecheck leiningen dependency feel free to clone this: https://github.com/scarytom/proptdd

@pholser

pholser commented May 28, 2013

Copy link
Copy Markdown

@tcmak

tcmak commented May 28, 2013

Copy link
Copy Markdown

I tried qc.js before. The syntax is a little weird, but usable: https://bitbucket.org/darrint/qc.js/

(oh... it's on bitbucket!)

@kolman

kolman commented Oct 23, 2013

Copy link
Copy Markdown

What about Haskell? After all, QuickCheck was first written in it, right?

@newswim

newswim commented Jun 27, 2017

Copy link
Copy Markdown

@dubzzz

dubzzz commented Feb 2, 2018

Copy link
Copy Markdown

Typescript, JavaScript - https://github.com/dubzzz/fast-check

@feeeper

feeeper commented Feb 27, 2018

Copy link
Copy Markdown

FsCheck is on github now: https://github.com/fscheck/FsCheck

@jlink

jlink commented Jan 25, 2019

Copy link
Copy Markdown

@moodmosaic

Copy link
Copy Markdown

.NET (C#, F#, VB): There's also Hedgehog.

@pragdave

Copy link
Copy Markdown

For Elixir and Erlang, there's https://github.com/pragdave/quixir

@flyingmutant

Copy link
Copy Markdown

Go has https://github.com/flyingmutant/rapid (written by me), which tries to provide most of Hypothesis goodness in idiomatic Go.

@sageserpent-open

sageserpent-open commented Jul 29, 2024

Copy link
Copy Markdown

Java and Scala - https://github.com/sageserpent-open/americium.

Two APIs specialised for each language, you can mix them up too.

Shrinkage is built-in, you don't write any custom shrinkage code. Shrinkage respects any invariants you set up in your generated test data.

Integrates with JUnit5, or can be used inline by tests using other test frameworks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment