Dal_node.Mockup
This module provides a mock HTTP server for selected RPCs. It responds to registered routes with mock data and fails all other requests. It is similar with the Proxy
module.
Creates a route for the mockup, containing a path_pattern
pattern and a callback
. The callback
is provided with the path
actually matched and is used to retrieve the DAL node answer for the given path
.
val run : t -> port:int -> unit
Starts the mockup server.
val stop : t -> unit
Stops the mockup server.