Liking cljdoc? Tell your friends :D

easy-assert.matchers


default-matchersclj

A map of default matcher functions.

Matchers: :is-equal-to - Checks if the actual value is equal to the expected value. :is-not-equal-to - Checks if the actual value is not equal to the expected value. :is - Alias for :is-equal-to. :is-not - Alias for :is-not-equal-to. :starts-with - Checks if the actual string starts with the expected string. :has-size - Checks if the collection has the expected size. :includes - Checks if the actual collection includes all the expected elements. :does-not-include - Checks if the actual collection does not include any of the expected elements. :exception-has-message - Checks if the exception has the expected message. :exception-caused-by - Checks if the exception was caused by the expected cause.

A map of default matcher functions.

Matchers:
  :is-equal-to           - Checks if the actual value is equal to the expected value.
  :is-not-equal-to       - Checks if the actual value is not equal to the expected value.
  :is                    - Alias for :is-equal-to.
  :is-not                - Alias for :is-not-equal-to.
  :starts-with           - Checks if the actual string starts with the expected string.
  :has-size              - Checks if the collection has the expected size.
  :includes              - Checks if the actual collection includes all the expected elements.
  :does-not-include      - Checks if the actual collection does not include any of the expected elements.
  :exception-has-message - Checks if the exception has the expected message.
  :exception-caused-by   - Checks if the exception was caused by the expected cause.
sourceraw docstring

does-not-include?clj

(does-not-include? actual expected)

Checks if the actual collection does not include any of the expected elements.

Parameters: actual - The actual collection. expected - The expected elements.

Returns: A vector containing a boolean indicating if the actual collection does not include any of the expected elements and a message if it does.

Checks if the actual collection does not include any of the expected elements.

Parameters:
  `actual`   - The actual collection.
  `expected` - The expected elements.

Returns:
  A vector containing a boolean indicating if the actual collection does not include any of the expected elements and a message if it does.
sourceraw docstring

exception-caused-by?clj

(exception-caused-by? exception expected)

Checks if the exception was caused by the expected cause.

Parameters: exception - The exception. expected - The expected cause.

Returns: A vector containing a boolean indicating if the exception was caused by the expected cause and a message if it was not.

Checks if the exception was caused by the expected cause.

Parameters:
  `exception` - The exception.
  `expected`  - The expected cause.

Returns:
  A vector containing a boolean indicating if the exception was caused by the expected cause and a message if it was not.
sourceraw docstring

exception-has-message?clj

(exception-has-message? exception expected)

Checks if the exception has the expected message.

Parameters: exception - The exception. expected - The expected message.

Returns: A vector containing a boolean indicating if the exception has the expected message and a message if it does not.

Checks if the exception has the expected message.

Parameters:
  `exception` - The exception.
  `expected`  - The expected message.

Returns:
  A vector containing a boolean indicating if the exception has the expected message and a message if it does not.
sourceraw docstring

has-size?clj

(has-size? actual expected)

Checks if the collection has the expected size.

Parameters: actual - The actual collection. expected - The expected size.

Returns: A vector containing a boolean indicating if the collection has the expected size and a message if it does not.

Checks if the collection has the expected size.

Parameters:
  `actual`   - The actual collection.
  `expected` - The expected size.

Returns:
  A vector containing a boolean indicating if the collection has the expected size and a message if it does not.
sourceraw docstring

includes?clj

(includes? actual expected)

Checks if the actual collection includes all the expected elements.

Parameters: actual - The actual collection. expected - The expected elements.

Returns: A vector containing a boolean indicating if the actual collection includes all the expected elements and a message if it does not.

Checks if the actual collection includes all the expected elements.

Parameters:
  `actual`   - The actual collection.
  `expected` - The expected elements.

Returns:
  A vector containing a boolean indicating if the actual collection includes all the expected elements and a message if it does not.
sourceraw docstring

is-equal-to?clj

(is-equal-to? actual expected)

Checks if the actual value is equal to the expected value.

Parameters: actual - The actual value. expected - The expected value.

Returns: A vector containing a boolean indicating if the values are equal and a message if they are not.

Checks if the actual value is equal to the expected value.

Parameters:
  `actual`   - The actual value.
  `expected` - The expected value.

Returns:
  A vector containing a boolean indicating if the values are equal and a message if they are not.
sourceraw docstring

is-not-equal-to?clj

(is-not-equal-to? actual expected)

Checks if the actual value is not equal to the expected value.

Parameters: actual - The actual value. expected - The expected value.

Returns: A vector containing a boolean indicating if the values are not equal and a message if they are.

Checks if the actual value is not equal to the expected value.

Parameters:
  `actual`   - The actual value.
  `expected` - The expected value.

Returns:
  A vector containing a boolean indicating if the values are not equal and a message if they are.
sourceraw docstring

starts-with?clj

(starts-with? actual expected)

Checks if the actual string starts with the expected string.

Parameters: actual - The actual string. expected - The expected starting string.

Returns: A vector containing a boolean indicating if the actual string starts with the expected string and a message if it does not.

Checks if the actual string starts with the expected string.

Parameters:
  `actual`   - The actual string.
  `expected` - The expected starting string.

Returns:
  A vector containing a boolean indicating if the actual string starts with the expected string and a message if it does not.
sourceraw docstring

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

× close