ExpectationBase<Actual, Return, Param> class abstract

Internals for expect Internals for expect

Implementers
Available Extensions

Constructors

ExpectationBase(Actual actual, {Matcher matcherBuilder(Matcher)?})
Internals for expect

Properties

actual → Actual
The value that is tested
final
hashCode int
The hash code for this object.
no setterinherited
not ExpectationBase<Actual, Return, Param>
Reverse the expectation
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

createMatcher(Matcher match) → Matcher
Apply transformations to a matcher.
isA<T>() → Return
Returns a matcher that matches objects with type T.
isNull() → Return
A matcher that matches any null value.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
runMatcher(Matcher match) → Return
Expect that actual matches with a Matcher from the Dart SDK.
toBe(Param expected) → Return
Returns a matches that matches if the value is the same instance as expected, using identical.
toBeFalsy() → Return
Returns a matcher that matches any value to be false or null.
toBeNull() → Return
A matcher that matches any null value.
toBeTruthy() → Return
Returns a matcher that matches any value that is not false or null.
toContain(Object? expected) → Return
Returns a matcher that matches if the match argument contains the expected value.
toEqual(Param expected, [int limit = 100]) → Return
Returns a matcher that matches if the value is structurally equal to expected.
toHaveLength(Object? matcher) → Return
Returns a matcher that matches if an object has a length property that matches matcher.
toMatch(Pattern re) → Return
Returns a matcher that matches if the match argument is a string and matches the regular expression given by re.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited