spec/models/brick_spec.rb in kuhsaft-2.0.3 vs spec/models/brick_spec.rb in kuhsaft-2.1.0
- old
+ new
@@ -34,11 +34,11 @@
end
end
describe '#parents' do
it 'returns the chain of parents' do
- item1, item2, item3 = mock, mock, Kuhsaft::Brick.new
+ item1, item2, item3 = double, double, Kuhsaft::Brick.new
item2.stub(:brick_list).and_return(item1)
item3.stub(:brick_list).and_return(item2)
item3.parents.should == [item1, item2]
end
end
@@ -54,10 +54,10 @@
brick = Kuhsaft::Brick.new
brick.has_siblings?.should be_false
end
it 'returns true if the brick has siblings' do
- item1, item2, item3 = mock, mock, Kuhsaft::Brick.new
+ item1, item2, item3 = double, double, Kuhsaft::Brick.new
item1.stub(:bricks).and_return([item2, item3])
item2.stub(:brick_list).and_return(item1)
item3.stub(:brick_list).and_return(item1)
item3.has_siblings?.should be_true
end