mirror of
https://gitea.invidious.io/iv-org/shard-spectator.git
synced 2024-08-15 00:53:35 +00:00
Add test for fix, fix test for range_matcher
This commit is contained in:
parent
ce9bf918c1
commit
83ac420273
2 changed files with 20 additions and 2 deletions
|
@ -13,13 +13,14 @@ module Spectator::Matchers
|
|||
|
||||
# Returns a new matcher, with the same bounds, but uses an inclusive range.
|
||||
def inclusive
|
||||
new_range = Range.new(range.begin, range.end, exclusive: false)
|
||||
expected = TestValue.new(new_range, label)
|
||||
label = expected.label
|
||||
new_range = Range.new(range.begin, label)
|
||||
RangeMatcher.new(expected)
|
||||
end
|
||||
|
||||
# Returns a new matcher, with the same bounds, but uses an exclusive range.
|
||||
def exclusive
|
||||
label = expected.label
|
||||
new_range = Range.new(range.begin, range.end, exclusive: true)
|
||||
expected = TestValue.new(new_range, label)
|
||||
RangeMatcher.new(expected)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue