Wrappers around matcher-combinators library functions for use in Lazytest tests. Copies the docstrings from the matcher-combinators vars.
Wrappers around matcher-combinators library functions for use in Lazytest tests. Copies the docstrings from the matcher-combinators vars.
(match? matcher actual)Asserts that the actual matches the expected, where the expected can be a value, a predicate function, or a matcher-combinator.
(is (match? [0 1 2] (range 3)))
(is (match? (complement empty?) (range 3)))
(is (match? (matcher-combinators.matchers/in-any-order [zero? odd? even?]) (range 3)))
Asserts that the `actual` matches the `expected`, where the `expected` can be a value, a predicate function, or a matcher-combinator. ```clojure (is (match? [0 1 2] (range 3))) (is (match? (complement empty?) (range 3))) (is (match? (matcher-combinators.matchers/in-any-order [zero? odd? even?]) (range 3))) ```
(thrown-match? matcher expr)(thrown-match? ex-class matcher expr)Asserts that evaluating expr throws an exception where the exception's ex-data satisfies the provided matcher.
Asserts that evaluating expr throws an exception where the exception's ex-data satisfies the provided matcher.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |