blob: 4f440353e50b6484f7c995821ce772197563f601 (
plain)
1
2
3
4
5
6
7
8
9
10
|
require_relative '../../spec_helper'
require 'set'
describe "Set#pretty_print_cycle" do
it "passes the 'pretty print' representation of a self-referencing Set to the pretty print writer" do
pp = mock("PrettyPrint")
pp.should_receive(:text).with("#<Set: {...}>")
Set[1, 2, 3].pretty_print_cycle(pp)
end
end
|