Skip to content

Commit a0b7d0d

Browse files
bjfisheregon
authored andcommitted
Update Enumerator::Lazy#filter_map spec to test when results are false
1 parent c46f863 commit a0b7d0d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

core/enumerator/lazy/filter_map_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
(1..Float::INFINITY).lazy.filter_map { |i| i if i.odd? }.first(4).should == [1, 3, 5, 7]
1010
end
1111

12-
it "does not map nil results" do
13-
(1..Float::INFINITY).lazy.filter_map { |i| i.odd? ? i : nil }.first(4).should == [1, 3, 5, 7]
12+
it "does not map false results" do
13+
(1..Float::INFINITY).lazy.filter_map { |i| i.odd? ? i : false }.first(4).should == [1, 3, 5, 7]
1414
end
1515
end
1616
end

0 commit comments

Comments
 (0)