Hoogle Search

Within LTS Haskell 23.21 (ghc-9.8.4)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. module Test.QuickCheck

    The QuickCheck manual gives detailed information about using QuickCheck effectively. You can also try https://begriffs.com/posts/2017-01-14-design-use-quickcheck.html, a tutorial written by a user of QuickCheck. To start using QuickCheck, write down your property as a function returning Bool. For example, to check that reversing a list twice gives back the same list you can write:

    import Test.QuickCheck
    
    prop_reverse :: [Int] -> Bool
    prop_reverse xs = reverse (reverse xs) == xs
    
    You can then use QuickCheck to test prop_reverse on 100 random lists:
    >>> quickCheck prop_reverse
    +++ OK, passed 100 tests.
    
    To run more tests you can use the withMaxSuccess combinator:
    >>> quickCheck (withMaxSuccess 10000 prop_reverse)
    +++ OK, passed 10000 tests.
    
    To use QuickCheck on your own data types you will need to write Arbitrary instances for those types. See the QuickCheck manual for details about how to do that.

  2. module Test.Hspec.QuickCheck

    No documentation available.

  3. module Test.Tasty.QuickCheck

    This module allows to use QuickCheck properties in tasty.

  4. module Test.Hspec.Core.QuickCheck

    No documentation available.

  5. module Test.Hspec.Wai.QuickCheck

    No documentation available.

  6. QuickCheck :: Property -> Property

    quickcheck-simple Test.QuickCheck.Simple

    No documentation available.

  7. module Test.Predicates.QuickCheck

    QuickCheck integration for Predicate

  8. module Test.Chell.QuickCheck

    No documentation available.

  9. module Test.Sandwich.QuickCheck

    Functions for introducing QuickCheck tests into a Sandwich test tree. Modelled after Hspec's version. Documentation can be found here.

  10. quickCheck :: Testable prop => prop -> IO ()

    QuickCheck Test.QuickCheck

    Tests a property and prints the results to stdout. By default up to 100 tests are performed, which may not be enough to find all bugs. To run more tests, use withMaxSuccess. If you want to get the counterexample as a Haskell value, rather than just printing it, try the quickcheck-with-counterexamples package.

Page 1 of many | Next