(->mock-client mocks)
Creates a client that, when passed to any oth-client functions,
will cause them to return mock data as defined in mocks.
mocks
is a map of symbols to either data or functions. If a function
is passed, that function is executed with the same args as the mocked function.
If data is passed, the data is returned when the mock is called.
Note that enabling mocks disables malli validation of both inputs and outputs.
Creates a client that, when passed to any oth-client functions, will cause them to return mock data as defined in mocks. `mocks` is a map of symbols to either data or functions. If a function is passed, that function is executed with the same args as the mocked function. If data is passed, the data is returned when the mock is called. Note that enabling mocks disables malli validation of both inputs and outputs.
(->output success-codes output)
Creates a success or error map.
Creates a success or error map.
(decode json-string)
(make-mockable)
Replaces any functions marked :mockable in the current namespace with an implementation that supports returning mock values.
Replaces any functions marked :mockable in the current namespace with an implementation that supports returning mock values.
(opts->request opts)
Creates a clj-http request map from the opts passed in.
Creates a clj-http request map from the opts passed in.
(success-schema response-schema)
Given a response schema, returns a success schema that wraps that response
Given a response schema, returns a success schema that wraps that response
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close