package mock-ounit

  1. Overview
  2. Docs
OUnit wrapper for OCaml mock

Install

Dune Dependency

Authors

Maintainers

Sources

1.0.0.tar.gz
md5=67deb0f8161f966bef6a422349dd88ad
sha512=3cad4d869563f4f187cc388170186825e0259a3f0a2d0c956ba47cb1f22ce08860677d80c04451d0b448745d76fef7f1c87e11ac1130548cb8506d5bc5715cd8

README.md.html

Mock - configurable functions to test impure code

This package provides "mocks", fake functions that can be configured to return values or raise exceptions. It is possible to inspect their arguments after their execution. The API is greatly inspired by unittest.mock in Python.

There is no magic under the hood, it is "just" a reference to a function, but it makes it possible to have pleasant output like this in your tests:

A wrapper for OUnit is available as mock-ounit.

OCaml

Innovation. Community. Security.