org.scalactic.TripleEqualsSupport.CheckingEqualizer
Class used via an implicit conversion to enable two objects to be compared with ===
and !==
with a Boolean
result and an enforced type constraint between two object types. For example:
assert(a === b)
assert(c !== d)
You can also check numeric values against another with a tolerance. Here are some examples:
assert(a === (2.0 +- 0.1))
assert(c !== (2.0 +- 0.1))
Value parameters
leftSide
An object to convert to Equalizer
, which represents the value on the left side of a ===
or !==
invocation.
Attributes
Source
TripleEqualsSupport.scala
Graph
Reset zoom Hide graph Show graph
Supertypes
class Object
trait Matchable
class Any
Members list
Compare two objects for inequality, returning a Boolean
, using the Constraint
instance passed as constraint
.
Compare two objects for inequality, returning a Boolean
, using the Constraint
instance passed as constraint
.
Value parameters
constraint
an implicit Constraint
instance that enforces a relationship between types L
and R
and defines a way of calculating equality for objects of type L
rightSide
the object to compare for inequality with leftSide
, passed to the constructor
Attributes
Returns
true if the leftSide
and rightSide
objects are not equal according to the passed Constraint
instance.
Source
TripleEqualsSupport.scala
Determine whether a numeric object is outside the passed Spread
, returning a Boolean
.
Determine whether a numeric object is outside the passed Spread
, returning a Boolean
.
Value parameters
spread
the Spread
against which to compare the value passed to the constructor as leftSide
Attributes
Returns
true if the value passed to the constructor as leftSide
is not within the Spread
passed to this method.
Source
TripleEqualsSupport.scala
Compare two objects for equality, returning a Boolean
, using the Constraint
instance passed as constraint
.
Compare two objects for equality, returning a Boolean
, using the Constraint
instance passed as constraint
.
Value parameters
constraint
an implicit Constraint
instance that enforces a relationship between types L
and R
and defines a way of calculating equality for objects of type L
rightSide
the object to compare for equality with leftSide
, passed to the constructor
Attributes
Returns
true if the leftSide
and rightSide
objects are equal according to the passed Constraint
instance.
Source
TripleEqualsSupport.scala
Determine whether a numeric object is within the passed Spread
, returning a Boolean
.
Determine whether a numeric object is within the passed Spread
, returning a Boolean
.
Value parameters
spread
the Spread
against which to compare the value passed to the constructor as leftSide
Attributes
Returns
true if the value passed to the constructor as leftSide
is not within the Spread
passed to this method.
Source
TripleEqualsSupport.scala