package qcheck-stm

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Module with combinators and definitions to specify an STM test

type 'a ty = ..

Extensible type to represent result values

type ty +=
  1. | Unit : unit ty
  2. | Bool : bool ty
  3. | Char : char ty
  4. | Int : int ty
  5. | Int32 : int32 ty
  6. | Int64 : int64 ty
  7. | Float : float ty
  8. | String : string ty
  9. | Bytes : bytes ty
  10. | Exn : exn ty
  11. | Option : 'a ty -> 'a option ty
  12. | Result : 'a ty * 'b ty -> ('a, 'b) Stdlib.result ty
  13. | List : 'a ty -> 'a list ty
  14. | Array : 'a ty -> 'a array ty
  15. | Seq : 'a ty -> 'a Stdlib.Seq.t ty

A range of constructors to represent built-in types

type 'a ty_show = 'a ty * ('a -> string)

Combinator type to represent an OCaml type along with an associated to_string function

val unit : unit ty_show

Combinator to represent the unit type

val bool : bool ty_show

Combinator to represent the bool type

val char : char ty_show

Combinator to represent the char type

val int : int ty_show

Combinator to represent the int type

val int32 : int32 ty_show

Combinator to represent the int32 type

val int64 : int64 ty_show

Combinator to represent the int64 type

val float : float ty_show

Combinator to represent the float type

val string : string ty_show

Combinator to represent the string type

val bytes : bytes ty_show

Combinator to represent the bytes type

val option : 'a ty_show -> 'a option ty_show

option t builds a t option type representation

val exn : exn ty_show

Combinator to represent the exception type

val result : 'a ty_show -> 'b ty_show -> ('a, 'b) Stdlib.Result.t ty_show

result a b builds an (a,b) result type representation

val list : 'a ty_show -> 'a list ty_show

list t builds a t list type representation

val array : 'a ty_show -> 'a array ty_show

array t builds a t array type representation

val seq : 'a ty_show -> 'a Stdlib.Seq.t ty_show

seq t builds a t Seq.t type representation

type res =
  1. | Res : 'a ty_show * 'a -> res
val show_res : res -> string
module type Spec = sig ... end

The specification of a state machine.

module Internal : sig ... end
val protect : ('a -> 'b) -> 'a -> ('b, exn) Stdlib.result

protect f turns an exception-throwing function into a result-returning function.

OCaml

Innovation. Community. Security.