Skip to content
SPECIFICTION
Get listed

PropCheck vs QuickCheck

PropCheck

github.com

QuickCheck

hackage.haskell.org

Side by side

FigurePropCheckQuickCheck
Price fromFreeFree
Free planYesYes
Free trial——
Open source——
LinuxYesYes
Self-hostedYes—
Plans published11
Spec score · Property-Based Testing Tools8.0 (#7)7.3 (#16)
DependenciesThe README says PropCheck requires no external dependencies.The package lists dependencies including base, containers, random, splitmix, template-haskell, and transformers.
GeneratorsIt includes generators for common Ruby data types and a DSL for defining custom generators.QuickCheck provides combinators for defining test data generators.
LicenseThe project is released under the MIT License.The package is licensed under BSD-3-Clause.
PurposePropCheck is a Ruby library for property-based testing that checks assertions against generated inputs.QuickCheck is a Haskell library for random testing of program properties by checking specifications against randomly generated cases.

Plans

PropCheck

  • Community libraryFree

PropCheck pricing →

QuickCheck

  • QuickCheckFree

QuickCheck pricing →

In their own words

PropCheck

PropCheck is a Ruby library for property-based testing: it generates inputs and checks whether assertions hold across them. When a generated example fails, it tries to simplify that case into a smaller counterexample. Built-in generators cover integers, floats, strings, symbols, arrays, hashes, sets, dates, times and datetimes. A generator DSL lets developers define their own, while the API also supports mapping and binding values, alternatives and weighted frequency choices.

Before, after and around hooks provide setup and cleanup around generated examples. The README gives usage examples for RSpec, MiniTest, test-unit and vanilla Ruby, and says the library has no external dependencies. PropCheck requires Ruby 2.5.1 or later and is released under the MIT License. It is available as a free Community library. Installation can be done through a Gemfile or with `gem install prop_check`. For generated examples involving a database, the README recommends cleaning database state around each example and mentions DatabaseCleaner. Stateful property testing is described as a possible future separate add-on.

Visit github.com

QuickCheck

QuickCheck is a free Haskell library for testing program properties against randomly generated cases. Developers write specifications with QuickCheck combinators and can use combinators to define test-data generators and inspect generated-data distributions. It supports stateful testing, reproducible failures and shrinking failing cases. Monadic property testing is provided through the Test.QuickCheck.Monadic module. The package README describes adding QuickCheck to project dependencies for use in tests or a REPL. A companion package, quickcheck-instances, supplies instances for types in Haskell Platform packages, with additional dependencies. QuickCheck is licensed under BSD-3-Clause and lists dependencies including base, containers, random, splitmix, template-haskell and transformers. Hackage reports it tested with GHC versions from 8.10 up to but not including 9.15, as well as Hugs. A make-hugs script creates a Hugs-compatible version and may be useful for other non-GHC implementations. Hackage lists QuickCheck-2.18.0.0 as a downloadable Cabal source package. The listed package plan costs nothing.

Visit hackage.haskell.org