Debug.QuickCheck

| Haskell Core Libraries (base package) | Parent | Contents | Index
Debug.QuickCheck |
Portability | portable
Stability | experimental
Maintainer | libraries@haskell.org
Description
QuickCheck v.0.2 DRAFT implementation; last update 000104. Koen Claessen, John Hughes. This file represents work in progress, and might change at a later date.
quickCheck :: (Testable a) => a -> IO ()
verboseCheck :: (Testable a) => a -> IO ()
test :: (Testable a) => a -> IO ()
data Config
Constructors
Config |
configMaxTest :: Int |
configMaxFail :: Int |
configSize :: (Int -> Int) |
configEvery :: (Int -> [String] -> String) |
check :: (Testable a) => Config -> a -> IO ()
forAll :: (Show a, Testable b) => Gen a -> (a -> b) -> Property
(==>) :: (Testable a) => Bool -> a -> Property
label :: (Testable a) => String -> a -> Property
collect :: (Show a, Testable b) => a -> b -> Property
classify :: (Testable a) => Bool -> String -> a -> Property
trivial :: (Testable a) => Bool -> a -> Property
data Gen a
Instances
Functor Gen
Monad Gen
elements :: [a] -> Gen a
two :: (Monad m) => m a -> m (a, a)
three :: (Monad m) => m a -> m (a, a, a)
four :: (Monad m) => m a -> m (a, a, a, a)
sized :: (Int -> Gen a) -> Gen a
resize :: Int -> Gen a -> Gen a
choose :: (Random a) => (a, a) -> Gen a
oneof :: [Gen a] -> Gen a
frequency :: [(Int, Gen a)] -> Gen a
vector :: (Arbitrary a) => Int -> Gen [a]
class Arbitrary a where
Methods
arbitrary :: Gen a
coarbitrary :: a -> Gen b -> Gen b
Instances
Arbitrary ()
Arbitrary Bool
Arbitrary Int
Arbitrary Integer
Arbitrary Float
Arbitrary Double
(Arbitrary a, Arbitrary b) => Arbitrary (a, b)
(Arbitrary a, Arbitrary b, Arbitrary c) => Arbitrary (a, b, c)
(Arbitrary a, Arbitrary b, Arbitrary c, Arbitrary d) => Arbitrary (a, b, c, d)
(Arbitrary a) => Arbitrary [a]
(Arbitrary a, Arbitrary b) => Arbitrary (a -> b)
Arbitrary (Poly a)
rand :: Gen StdGen
promote :: (a -> Gen b) -> Gen (a -> b)
variant :: Int -> Gen a -> Gen a
class Testable a where
Methods
property :: a -> Property
Instances
Testable ()
Testable Bool
Testable Result
Testable Property
(Arbitrary a, Show a, Testable b) => Testable (a -> b)
data Property
Instances
Testable Property
data Result
Constructors
Result |
ok :: (Maybe Bool) |
stamp :: [String] |
arguments :: [String] |
Instances
Testable Result
generate :: Int -> StdGen -> Gen a -> a
evaluate :: (Testable a) => a -> Gen Result
Produced by Haddock version 0.4