mirror of
https://github.com/c-cube/ocaml-containers.git
synced 2025-12-06 03:05:28 -05:00
updated doc
This commit is contained in:
parent
4c46f9a697
commit
3f9a33e1d0
1 changed files with 8 additions and 4 deletions
12
qCheck.mli
12
qCheck.mli
|
|
@ -51,14 +51,18 @@ Examples:
|
|||
|
||||
- Not all lists are sorted:
|
||||
|
||||
{[QCheck.run ~n:10 ~pp:QCheck.PP.(list int)
|
||||
QCheck.Arbitrary.(list small_int) (fun l -> l = List.sort compare l);;
|
||||
{[
|
||||
let test = QCheck.(mk_test ~n:10 ~pp:QCheck.PP.(list int)
|
||||
QCheck.Arbitrary.(list small_int) (fun l -> l = List.sort compare l));;
|
||||
QCheck.run test;;
|
||||
]}
|
||||
|
||||
- List.rev is involutive:
|
||||
|
||||
{[QCheck.run ~n:1000 QCheck.Arbitrary.(list alpha)
|
||||
(fun l -> List.rev (List.rev l) = l)
|
||||
{[
|
||||
let test = QCheck.mk_test ~n:1000 QCheck.Arbitrary.(list alpha)
|
||||
(fun l -> List.rev (List.rev l) = l);;
|
||||
QCheck.run test;;
|
||||
]}
|
||||
|
||||
- generate a tree using {! Arbitrary.fix} :
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue