pub fn close_to<'a, T>(expected: T, eps: T) -> Box<dyn Matcher<'a, T> + 'a>
Expand description
Matches if the asserted value is in an epsilon range around the expected value.
If floating point values are compared for equality this matcher should be used instead of equal_to
#Examples
use galvanic_assert::matchers::*;
assert_that!(&(1.2 + 3.14), close_to(4.34, 0.00001));