diff --git a/spec/helpers/expectations_helper.cr b/spec/helpers/expectations_helper.cr index bee6e18..6d0246c 100644 --- a/spec/helpers/expectations_helper.cr +++ b/spec/helpers/expectations_helper.cr @@ -19,8 +19,8 @@ end def new_expectation(expected : ExpectedType = 123, actual : ActualType = 123) forall ExpectedType, ActualType partial = new_partial(actual, "foo") matcher = new_matcher("bar", expected) - matched = matcher.match?(partial) - Spectator::Expectations::Expectation.new(matched, false, partial, matcher) + match_data = matcher.match(partial) + Spectator::Expectations::Expectation.new(match_data, false) end def new_satisfied_expectation(value : T = 123) forall T diff --git a/src/spectator/expectations/expectation.cr b/src/spectator/expectations/expectation.cr index 731f3b2..9a37858 100644 --- a/src/spectator/expectations/expectation.cr +++ b/src/spectator/expectations/expectation.cr @@ -7,7 +7,7 @@ module Spectator::Expectations # when the expectation was evaluated. # The *negated* flag and `MatchData#matched?` flag # are mutually-exclusive in this context. - def initialize(@match_data : MatchData, @negated : Bool) + def initialize(@match_data : Spectator::Matchers::MatchData, @negated : Bool) end # Indicates whether the expectation was satisifed.