Struct galvanic_assert::matchers::Any [] [src]

pub struct Any<'a, T: 'a> {
    pub matcher: Box<Matcher<'a, T> + 'a>,
    pub next: Option<Box<Any<'a, T>>>,
}

A Matcher struct which joins multiple Matchers disjunctively.

Use of() to create a new Matcher and or() to add further Matchers.

Examples

use galvanic_assert::matchers::*;
assert_that!(&(1+1), Any::of(lt(0)).or(gt(5)).or(not(eq(3))));

Fields

Methods

impl<'a, T: 'a> Any<'a, T>
[src]

[src]

Creates a new conjunctive Matcher starting with the given Matcher.

[src]

Adds the given Matcher disjunctively.

Trait Implementations

impl<'a, T: 'a> Matcher<'a, T> for Any<'a, T>
[src]

[src]

Checks the passed value if it satisfies the Matcher. Read more