struct Spectator::Expectations::Expectation
- Spectator::Expectations::Expectation
- Struct
- Value
- Object
Overview
Result of evaluating a matcher on an expectation partial.
Defined in:
spectator/expectations/expectation.crConstructors
-
.new(match_data : Matchers::MatchData, source : Source)
Creates the expectation.
Instance Method Summary
- #description
-
#failure?
Indicates that the expectation was not satisified.
-
#failure_message
Description of why the match failed.
-
#failure_message?
Description of why the match failed.
-
#satisfied?
Indicates whether the matcher was satisified.
-
#source : Source
Location where this expectation was defined.
-
#to_json(json : JSON::Builder)
Creates the JSON representation of the expectation.
-
#values
Additional information about the match, useful for debug.
-
#values?
Additional information about the match, useful for debug.
Instance methods inherited from class Object
should(matcher)
should,
should_eventually(matcher)
should_eventually,
should_never(matcher)
should_never,
should_not(matcher)
should_not
Constructor Detail
Creates the expectation.
Instance Method Detail
def values?
#
Additional information about the match, useful for debug. If nil, then the match was successful.