Liking cljdoc? Tell your friends :D

lazytest.test-case


identifierclj

(identifier result)
source

test-casecljmacro

(test-case f)

Sets metadata on function f identifying it as a test case. A test case function may execute arbitrary code and may have side effects. It should throw an exception to indicate failure. Returning without throwing an exception indicates success.

Additional identifying metadata may be placed on the function, such as :ns-name and :doc.

Sets metadata on function f identifying it as a test case. A test
case function may execute arbitrary code and may have side effects.
It should throw an exception to indicate failure. Returning without
throwing an exception indicates success.

Additional identifying metadata may be placed on the function, such
as :ns-name and :doc.
sourceraw docstring

test-case-resultclj

(test-case-result type' source)
(test-case-result type' source thrown)

Creates a test case result map with keys :pass?, :source, and :thrown.

pass? is true if the test case passed successfully, false otherwise.

source is the test case object that returned this result.

thrown is the exception (Throwable) thrown by a failing test case.

Creates a test case result map with keys :pass?, :source, and :thrown.

pass? is true if the test case passed successfully, false otherwise.

source is the test case object that returned this result.

thrown is the exception (Throwable) thrown by a failing test case.
sourceraw docstring

test-case-result?clj

(test-case-result? x)

True if x is a test case result.

True if x is a test case result.
sourceraw docstring

test-case?clj

(test-case? x)

True if x is a test case.

True if x is a test case.
sourceraw docstring

try-test-caseclj

(try-test-case f)

Executes a test case function. Catches all Throwables. Returns a map with the following key-value pairs:

:source - the input function :pass? - true if the function ran without throwing :thrown - the Throwable instance if thrown

Executes a test case function. Catches all Throwables. Returns a
map with the following key-value pairs:

  :source - the input function
  :pass?  - true if the function ran without throwing
  :thrown - the Throwable instance if thrown
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close