Expand description
Modules
Core types for the library.
docs
docsrs
User Docs
The formatters provided by this crate.
The matchers provided by this crate.
Macros
Structs
An error that occurs in a matcher.
Functions
Succeeds when all of the passed matchers succeed.
Succeeds when any of the passed matchers succeed.
approx_eq_f32
float
Succeeds when the actual
f32
value approximately equals the expected f32
value.approx_eq_f64
float
Succeeds when the actual
f64
value approximately equals the expected f64
value.Succeeds when the actual time approximately equals the expected time.
Succeeds when the actual value equals the default value for the type.
Succeeds when the actual value is an existing directory.
Succeeds when the actual value is empty.
Succeeds when the actual value is an existing file.
Succeeds when the actual value is
false
.Succeeds when the actual value is greater than or equal to the expected value.
Succeeds when the actual value is greater than the expected value.
Succeeds when the actual value is contained in the expected collection.
Succeeds when the actual value is less than or equal to the expected value.
Succeeds when the actual value is less than the expected value.
Succeeds when the actual value is an existing regular file.
Succeeds when the actual value is sorted in ascending order.
Succeeds when the actual value is sorted according to the given predicate.
Succeeds when the actual value is sorted in descending order.
Succeeds when the actual value is an existing symbolic link.
Succeeds when the actual value is
true
.Succeeds when the actual integer value is
0
.Succeeds when the actual value contains exactly the given elements, in any order.
Succeeds when the actual value contains the given element.
Succeeds when the actual value contains all the given elements.
Succeeds when the actual value contains the expected substring.
Succeeds when each of the passed matchers succeeds.
eq_casefold
casefold
Succeeds when the actual string equals the expected string regardless of case.
Succeeds when the actual value equals the expected value.
Succeeds when the matcher succeeds for every element of the actual value.
Succeeds when the actual value has the given length.
Succeeds when the actual value has the expected prefix.
Succeeds when the actual value has the expected suffix.
Infallibly map each value of an iterator by applying a function to it.
Fallibly map each value of an iterator by applying a function to it.
Infallibly map the input value by applying a function to it.
Succeeds when any of the fields of a struct succeed.
Succeeds when all the fields of a struct succeed.
match_json
json
Succeeds when the actual string and the expected string are equivalent JSON.
Succeeds when the given pattern matches.
match_regex
regex
Succeeds when the actual value matches the given regular expression.
Negates the matcher passed to it.
Fallibly map the input value by applying a function to it.
Attaches a context string to a matcher that will appear in the failure output.
Attaches a lazily evaluated context string to a matcher that will appear in the failure output.