| Safe Haskell | None |
|---|---|
| Language | Haskell98 |
Propellor.Types.ResultCheck
- data UncheckedProperty i
- unchecked :: Property i -> UncheckedProperty i
- checkResult :: (Checkable p i, LiftPropellor m) => m a -> (a -> m Result) -> p i -> Property i
- check :: (Checkable p i, LiftPropellor m) => m Bool -> p i -> Property i
- class Checkable p i
- assume :: Checkable p i => p i -> Result -> Property i
Documentation
data UncheckedProperty i Source
This is a Property but its Result is not accurate; in particular
it may return NoChange despite having made a change.
However, when it returns MadeChange, it really did make a change,
and FailedChange is still an error.
Instances
unchecked :: Property i -> UncheckedProperty i Source
Use to indicate that a Property is unchecked.
Arguments
| :: (Checkable p i, LiftPropellor m) | |
| => m a | Run before ensuring the property. |
| -> (a -> m Result) | Run after ensuring the property. Return |
| -> p i | |
| -> Property i |
Checks the result of a property. Mostly used to convert a
UncheckedProperty to a Property, but can also be used to further
check a Property.
check :: (Checkable p i, LiftPropellor m) => m Bool -> p i -> Property i Source
Makes a Property or an UncheckedProperty only run
when a test succeeds.
Minimal complete definition
checkedProp, preCheckedProp