Skip to content

Commit ab49e8a

Browse files
committed
[ruby/pp] [Feature #21389] Update rubyspec
1 parent 674e2ca commit ab49e8a

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

spec/ruby/core/set/pretty_print_cycle_spec.rb

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,12 @@
33
describe "Set#pretty_print_cycle" do
44
it "passes the 'pretty print' representation of a self-referencing Set to the pretty print writer" do
55
pp = mock("PrettyPrint")
6-
pp.should_receive(:text).with("#<Set: {...}>")
6+
ruby_version_is(""..."3.5") do
7+
pp.should_receive(:text).with("#<Set: {...}>")
8+
end
9+
ruby_version_is("3.5") do
10+
pp.should_receive(:text).with("Set[...]")
11+
end
712
Set[1, 2, 3].pretty_print_cycle(pp)
813
end
914
end

0 commit comments

Comments
 (0)