Quick Check

QuickCheck is an automated specification-based testing tool for use with HaskellLanguage. It's reportedly good for finding boundary conditions.

The homepage is http://www.cs.chalmers.se/~rjmh/QuickCheck/

There is a paper from ICFP 2000 about it here: http://www.md.chalmers.se/~koen/Papers/quick.ps

QuickCheck is really nice because you establish certain conditions that should hold for inputs. The first example given in the paper is that any list when reversed twice should be equal to the original list. For larger structures, you can write a simple generator that creates instances of your data and checks to see if they always meet the criteria you've specified. You'd be surprised how many corner cases this finds. --ShaeErisson

I found this indispensable when I wrote an implementation of 2-3-4 trees in Haskell. If there was some way of minimizing counterexamples to specifications then this would be the best thing ever.

It can "shrink" test cases now, so it is officially the best thing ever.
CategoryTesting ExecutableSpecifications CategoryHaskell

View edit of April 6, 2011 or FindPage with title or text search