Legend:
Library
Module
Module type
Parameter
Class
Class type
Library
Module
Module type
Parameter
Class
Class type
Assume the given precondition holds. A test won't fail if the precondition (the boolean argument) is false, but it will be discarded. Running tests counts how many instances were discarded for not satisfying preconditions.
Assume the given (lazy) precondition holds. See assume
.
raise ~e ~f ~x
is true if and only if calling f x
raises the exception exn
.
For instance (on lists): let prop l = Prop.(assume (l = []); raises ~f:List.hd ~x:l ~e:(Failure "hd"));;