Liking cljdoc? Tell your friends :D

lazytest.experimental.interfaces.xunit

EXPERIMENTAL. COULD BE CHANGED AT ANY TIME. Please share usage reports at https://github.com/noahtheduke/lazytest/issues.

An adaption of the xUnit style of test frameworks. A fairly simple aliasing of the lazytest.core macros:

Example:

(ns noahtheduke.example-test
  (:require
   [lazytest.experimental.interfaces.xunit :refer [defsuite suite test-case assert!]]))

(defsuite defsuite-test
  (suite "defsuite works"
    (assert! true "expect works inside"))
  (suite "suite works"
    (test-case "test-case works"
      (assert! true))))
EXPERIMENTAL. COULD BE CHANGED AT ANY TIME. Please share usage reports at <https://github.com/noahtheduke/lazytest/issues>.

An adaption of the [xUnit](https://en.wikipedia.org/wiki/XUnit) style of test frameworks. A fairly simple aliasing of the [[lazytest.core]] macros:

* [[lazytest.core/defdescribe]] -> [[defsuite]]
* [[lazytest.core/describe]] -> [[suite]]
* [[lazytest.core/it]] -> [[test-case]]
* [[lazytest.core/expect]] -> [[assert!]]

Example:

```clojure
(ns noahtheduke.example-test
  (:require
   [lazytest.experimental.interfaces.xunit :refer [defsuite suite test-case assert!]]))

(defsuite defsuite-test
  (suite "defsuite works"
    (assert! true "expect works inside"))
  (suite "suite works"
    (test-case "test-case works"
      (assert! true))))
```
raw docstring

assert!cljmacro

(assert! expr)
(assert! expr msg)

Alias of lazytest.core/expect for the xUnit interface.

Alias of [[lazytest.core/expect]] for the xUnit interface.
sourceraw docstring

defsuitecljmacro

(defsuite test-name & children)
(defsuite test-name doc? attr-map? & children)

Alias of lazytest.core/defdescribe for the xUnit interface.

Alias of [[lazytest.core/defdescribe]] for the xUnit interface.
sourceraw docstring

suitecljmacro

(suite doc & children)
(suite doc attr-map? & children)

Alias of lazytest.core/describe for the xUnit. Unrelated to lazytest.suite/suite.

Alias of [[lazytest.core/describe]] for the xUnit. Unrelated to [[lazytest.suite/suite]].
sourceraw docstring

test-casecljmacro

(test-case doc & body)
(test-case doc|sym? attr-map? & body)

Alias of lazytest.core/it for the xUnit interface.

Alias of [[lazytest.core/it]] for the xUnit interface.
sourceraw docstring

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

× close