Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Test.MockCat.Param
Description
This module is a parameter of the mock function.
This parameter can be used when creating and verifying the mock.
Documentation
Instances
expect :: (a -> Bool) -> String -> Param a Source #
Create a conditional parameter.
When applying a mock function, if the argument does not satisfy this condition, an error occurs.
In this case, the specified label is included in the error message.
expect_ :: (a -> Bool) -> Param a Source #
Create a conditional parameter.
In applied a mock function, if the argument does not satisfy this condition, an error occurs.
Unlike
, it does not require a label, but the error message is displayed as [some condition].expect