Creates a new instance of CloseTo asymmetric matcher.
Expected value.
The number of decimal digits after the decimal point that must be equal.
If true, matches if the received value is not close to the expected value.
Symbol to identify asymmetric matcher.
ProtectedinverseIf true, the matcher will check for non-matching values.
ProtectedsampleThe sample value to match against.
Checks if the value matches.
The value to test.
true if the value matches, otherwise false.
Returns the expected type of the asymmetric matcher.
The expected type of the asymmetric matcher.
ProtectedgetReturns the context for the asymmetric matcher.
The context for the asymmetric matcher.
Returns a string representation of the asymmetric matcher for use in error messages.
A string representation of the asymmetric matcher for error messages.
Returns a string representation of the asymmetric matcher.
A string representation of the asymmetric matcher.
Assymmetric matcher that compares floating point numbers for approximate equality. Use it inside expect(value).toEqual(expected) to perform pattern matching. When just comparing two numbers, prefer expect(value).toBeCloseTo(expected[, numDigits]).
Usage