class Arbitrary t where
arbitrary :: Gen t
class CoArbitrary t where
coarbitrary :: forall r. t -> Gen r -> Gen r
data Result
= Success
| Failed String
instance showResult :: Show Result
(<?>) :: Boolean -> String -> Result
instance arbChar :: Arbitrary S.Char
instance coarbChar :: CoArbitrary S.Char
instance arbNumber :: Arbitrary Number
instance coarbNumber :: CoArbitrary Number
instance arbBoolean :: Arbitrary Boolean
instance coarbBoolean :: CoArbitrary Boolean
instance arbString :: Arbitrary String
instance coarbString :: CoArbitrary String
newtype AlphaNumString
= AlphaNumString String
instance arbAlphaNumString :: Arbitrary AlphaNumString
instance coarbAlphaNumString :: CoArbitrary AlphaNumString
instance arbTuple :: (Arbitrary a, Arbitrary b) => Arbitrary (Tuple a b)
instance coarbTuple :: (CoArbitrary a, CoArbitrary b) => CoArbitrary (Tuple a b)
instance arbEither :: (Arbitrary a, Arbitrary b) => Arbitrary (Either a b)
instance coarbEither :: (CoArbitrary a, CoArbitrary b) => CoArbitrary (Either a b)
instance arbMaybe :: (Arbitrary a) => Arbitrary (Maybe a)
instance coarbMaybe :: (CoArbitrary a) => CoArbitrary (Maybe a)
instance arbFunction :: (CoArbitrary a, Arbitrary b) => Arbitrary (a -> b)
instance coarbFunction :: (Arbitrary a, CoArbitrary b) => CoArbitrary (a -> b)
instance arbArray :: (Arbitrary a) => Arbitrary [a]
instance coarbArray :: (CoArbitrary a) => CoArbitrary [a]
class Testable prop where
test :: prop -> Gen Result
instance testableResult :: Testable Result
instance testableBoolean :: Testable Boolean
instance testableFunction :: (Arbitrary t, Testable prop) => Testable (t -> prop)
quickCheckPure :: forall prop. (Testable prop) => Number -> Number -> prop -> [Result]
type QC a = forall eff. Eff (err :: Exception, random :: Random, trace :: Trace | eff) a
quickCheck' :: forall prop. (Testable prop) => Number -> prop -> QC Unit
quickCheck :: forall prop. (Testable prop) => prop -> QC Unit
(===) :: forall a b. (Eq a, Show a) => a -> a -> Result
Self-documenting equality assertion
(/==) :: forall a b. (Eq a, Show a) => a -> a -> Result
Self-documenting inequality assertion
type LCG = Number
type Size = Number
type GenState = { size :: Size, newSeed :: LCG }
type GenOut a = { value :: a, state :: GenState }
data Gen a
repeatable :: forall a b. (a -> Gen b) -> Gen (a -> b)
stateful :: forall a. (GenState -> Gen a) -> Gen a
variant :: forall a. LCG -> Gen a -> Gen a
sized :: forall a. (Size -> Gen a) -> Gen a
resize :: forall a. Size -> Gen a -> Gen a
choose :: Number -> Number -> Gen Number
chooseInt :: Number -> Number -> Gen Number
oneOf :: forall a. Gen a -> [Gen a] -> Gen a
frequency :: forall a. Tuple Number (Gen a) -> [Tuple Number (Gen a)] -> Gen a
arrayOf :: forall a. Gen a -> Gen [a]
arrayOf1 :: forall a. Gen a -> Gen (Tuple a [a])
vectorOf :: forall a. Number -> Gen a -> Gen [a]
elements :: forall a. a -> [a] -> Gen a
runGen :: forall a. Gen a -> GenState -> GenOut a
evalGen :: forall a. Gen a -> GenState -> a
showSample' :: forall r a. (Show a) => Size -> Gen a -> Eff (trace :: Trace | r) Unit
showSample :: forall r a. (Show a) => Gen a -> Eff (trace :: Trace | r) Unit
uniform :: Gen Number
perturbGen :: forall a. Number -> Gen a -> Gen a
instance functorGen :: Functor Gen
instance applyGen :: Apply Gen
instance applicativeGen :: Applicative Gen
instance bindGen :: Bind Gen
instance monadGen :: Monad Gen