CheckOperators Module
Concise operator syntax for property-style checks.
Functions and values
| Function or value |
Description
|
||
Full Usage:
a <&> b
Parameters:
^T
-
The first required expectation.
b : ^T
-
The second required expectation.
Returns: ^T
A combined expectation that succeeds only when both input expectations succeed.
Modifiers: inline Type parameters: ^T |
Combines two expectations so that both must succeed.
|
||
Full Usage:
a <|> b
Parameters:
^T
-
The first alternative expectation.
b : ^T
-
The second alternative expectation.
Returns: ^T
A combined expectation that succeeds when either input expectation succeeds.
Modifiers: inline Type parameters: ^T |
Combines two expectations so that either one may succeed.
|
||
Full Usage:
expr |=> reference
Parameters:
Expr<('Args -> 'Testable)>
-
The quoted tested function under evaluation.
reference : 'Args -> 'Testable
-
The trusted reference implementation.
Modifiers: inline Type parameters: 'Args, 'Testable |
Runs the default equality-based throwing property check.
Example
Multiple items
module List from Microsoft.FSharp.Collections -------------------- type List<'T> = | op_Nil | op_ColonColon of Head: 'T * Tail: 'T list interface IReadOnlyList<'T> interface IReadOnlyCollection<'T> interface IEnumerable interface IEnumerable<'T> member GetReverseIndex: rank: int * offset: int -> int member GetSlice: startIndex: int option * endIndex: int option -> 'T list static member Cons: head: 'T * tail: 'T list -> 'T list member Head: 'T with get member IsEmpty: bool with get member Item: index: int -> 'T with get ... val rev: list: 'T list -> 'T list
val id: x: 'T -> 'T
|
||
Full Usage:
expr |=>> reference
Parameters:
Expr<('Args -> 'Testable)>
-
The quoted tested function under evaluation.
reference : 'Args -> 'Testable
-
The trusted reference implementation.
Returns: Expr<('Args -> 'Testable)>
The original quotation.
Modifiers: inline Type parameters: 'Args, 'Testable |
Runs the default equality-based throwing property check, then returns the quotation.
Example
Multiple items
module List from Microsoft.FSharp.Collections -------------------- type List<'T> = | op_Nil | op_ColonColon of Head: 'T * Tail: 'T list interface IReadOnlyList<'T> interface IReadOnlyCollection<'T> interface IEnumerable interface IEnumerable<'T> member GetReverseIndex: rank: int * offset: int -> int member GetSlice: startIndex: int option * endIndex: int option -> 'T list static member Cons: head: 'T * tail: 'T list -> 'T list member Head: 'T with get member IsEmpty: bool with get member Item: index: int -> 'T with get ... val rev: list: 'T list -> 'T list
val id: x: 'T -> 'T
val ignore: value: 'T -> unit
|
||
|
Runs a callback-built bool property check and raises immediately on failure.
Example
val expectedLength: int
val xs: 'a list
Multiple items
module List from Microsoft.FSharp.Collections -------------------- type List<'T> = | op_Nil | op_ColonColon of Head: 'T * Tail: 'T list interface IReadOnlyList<'T> interface IReadOnlyCollection<'T> interface IEnumerable interface IEnumerable<'T> member GetReverseIndex: rank: int * offset: int -> int member GetSlice: startIndex: int option * endIndex: int option -> 'T list static member Cons: head: 'T * tail: 'T list -> 'T list member Head: 'T with get member IsEmpty: bool with get member Item: index: int -> 'T with get ... val length: list: 'T list -> int
Multiple items
val int: value: 'T -> int (requires member op_Explicit) -------------------- type int = int32 -------------------- type int<'Measure> = int type 'T list = List<'T>
|
testify