Common Lisp Package: CL-NEO4J.TESTS

README:

FUNCTION

Public

Undocumented

RUN-ALL-TESTS

Private

RUN! (&OPTIONAL (TEST-SPEC *SUITE*))

Equivalent to (explain (run TEST-SPEC)).

Undocumented

GET-ID-FROM-DATA (DATA)

MACRO

Private

DEF-SUITE (NAME &KEY DESCRIPTION IN)

Define a new test-suite named NAME. IN (a symbol), if provided, causes this suite te be nested in the suite named by IN. NB: This macro is built on top of make-suite, as such it, like make-suite, will overrwrite any existing suite named NAME.

IN-SUITE (SUITE-NAME)

Set the *suite* special variable so that all tests defined after the execution of this form are, unless specified otherwise, in the test-suite named SUITE-NAME. See also: DEF-SUITE *SUITE*

IS (TEST &REST REASON-ARGS)

The DWIM checking operator. If TEST returns a true value a test-passed result is generated, otherwise a test-failure result is generated. The reason, unless REASON-ARGS is provided, is generated based on the form of TEST: (predicate expected actual) - Means that we want to check whether, according to PREDICATE, the ACTUAL value is in fact what we EXPECTED. (predicate value) - Means that we want to ensure that VALUE satisfies PREDICATE. Wrapping the TEST form in a NOT simply preducse a negated reason string.

SIGNALS (CONDITION-SPEC &BODY BODY)

Generates a pass if BODY signals a condition of type CONDITION. BODY is evaluated in a block named NIL, CONDITION is not evaluated.

TEST (NAME &BODY BODY)

Create a test named NAME. If NAME is a list it must be of the form: (name &key depends-on suite fixture compile-at profile) NAME is the symbol which names the test. DEPENDS-ON is a list of the form: (AND . test-names) - This test is run only if all of the tests in TEST-NAMES have passed, otherwise a single test-skipped result is generated. (OR . test-names) - If any of TEST-NAMES has passed this test is run, otherwise a test-skipped result is generated. (NOT test-name) - This is test is run only if TEST-NAME failed. AND, OR and NOT can be combined to produce complex dependencies. If DEPENDS-ON is a symbol it is interpreted as `(AND ,depends-on), this is accomadate the common case of one test depending on another. FIXTURE specifies a fixtrue to wrap the body in. If PROFILE is T profiling information will be collected as well.

Undocumented

WITH-TEST-NODES (NODES RELATIONS &BODY BODY)