test/twin/property_processor_test.rb in disposable-0.4.6 vs test/twin/property_processor_test.rb in disposable-0.4.7
- old
+ new
@@ -21,25 +21,25 @@
let(:twin) { AlbumTwin.new(Album.new("Live!", Artist.new, [Song.new(1), Song.new(2)])) }
it "yields twin, index" do
called = []
Disposable::Twin::PropertyProcessor.new(twin.class.definitions.get(:songs), twin).() { |v, i| called << [v.model, i] }
- called.inspect.must_equal %{[[#<struct PropertyProcessorTest::Song id=1>, 0], [#<struct PropertyProcessorTest::Song id=2>, 1]]}
+ expect(called.inspect).must_equal %{[[#<struct PropertyProcessorTest::Song id=1>, 0], [#<struct PropertyProcessorTest::Song id=2>, 1]]}
end
it "yields twin" do
called = []
Disposable::Twin::PropertyProcessor.new(twin.class.definitions.get(:songs), twin).() { |v| called << [v.model] }
- called.inspect.must_equal %{[[#<struct PropertyProcessorTest::Song id=1>], [#<struct PropertyProcessorTest::Song id=2>]]}
+ expect(called.inspect).must_equal %{[[#<struct PropertyProcessorTest::Song id=1>], [#<struct PropertyProcessorTest::Song id=2>]]}
end
it "allows nil collection" do
twin = AlbumTwin.new(Album.new("Live!", Artist.new, nil))
called = []
Disposable::Twin::PropertyProcessor.new(twin.class.definitions.get(:songs), twin).() { |v, i| called << [v.model, i] }
- called.inspect.must_equal %{[]}
+ expect(called.inspect).must_equal %{[]}
end
end
end