Copyright | (c) 2015-2018 Rudy Matela |
---|---|
License | 3-Clause BSD (see the file LICENSE) |
Maintainer | Rudy Matela <rudy@matela.com.br> |
Safe Haskell | Safe |
Language | Haskell2010 |
This module is part of LeanCheck, a simple enumerative property-based testing library.
QuickCheck-like interface to Test.LeanCheck
Documentation
check :: Testable a => a -> IO () Source #
Checks a property printing results on stdout
> check $ \xs -> sort (sort xs) == sort (xs::[Int]) +++ OK, passed 200 tests. > check $ \xs ys -> xs `union` ys == ys `union` (xs::[Int]) *** Failed! Falsifiable (after 4 tests): [] [0,0]
checkFor :: Testable a => Int -> a -> IO () Source #
Check a property for a given number of tests
printing results on stdout