mirror of
https://gitea.invidious.io/iv-org/shard-spectator.git
synced 2024-08-15 00:53:35 +00:00
Fix flipped expected and actual labels
NilMatcher output was correct, but variables were named incorrectly.
This commit is contained in:
parent
1219b19d89
commit
d5bef6f1da
2 changed files with 5 additions and 5 deletions
|
@ -34,13 +34,13 @@ module Spectator::Matchers
|
|||
# Describes the condition that satisfies the matcher.
|
||||
# This is informational and displayed to the end-user.
|
||||
def message
|
||||
"#{@values.expected_label} is #{@values.actual_label} (using ==)"
|
||||
"#{@values.actual_label} is #{@values.expected_label} (using ==)"
|
||||
end
|
||||
|
||||
# Describes the condition that won't satsify the matcher.
|
||||
# This is informational and displayed to the end-user.
|
||||
def negated_message
|
||||
"#{@values.expected_label} is not #{@values.actual_label} (using ==)"
|
||||
"#{@values.actual_label} is not #{@values.expected_label} (using ==)"
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -20,7 +20,7 @@ module Spectator::Matchers
|
|||
# Match data specific to this matcher.
|
||||
private struct MatchData(T) < MatchData
|
||||
# Creates the match data.
|
||||
def initialize(matched, @actual : T, @expected_label : String)
|
||||
def initialize(matched, @actual : T, @actual_label : String)
|
||||
super(matched)
|
||||
end
|
||||
|
||||
|
@ -35,13 +35,13 @@ module Spectator::Matchers
|
|||
# Describes the condition that satisfies the matcher.
|
||||
# This is informational and displayed to the end-user.
|
||||
def message
|
||||
"#{@expected_label} is nil"
|
||||
"#{@actual_label} is nil"
|
||||
end
|
||||
|
||||
# Describes the condition that won't satsify the matcher.
|
||||
# This is informational and displayed to the end-user.
|
||||
def negated_message
|
||||
"#{@expected_label} is not nil"
|
||||
"#{@actual_label} is not nil"
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue