spec/unit/veritas/relation/gateway/extend_spec.rb in veritas-do-adapter-0.0.6 vs spec/unit/veritas/relation/gateway/extend_spec.rb in veritas-do-adapter-0.0.7
- old
+ new
@@ -9,19 +9,21 @@
let(:adapter) { mock('Adapter') }
let(:relation) { mock('Relation', :extend => response) }
let(:response) { mock('New Relation', :kind_of? => true) }
let!(:object) { described_class.new(adapter, relation) }
let(:args) { stub }
- let(:block) { proc {} }
+ let(:block) { lambda { |context| } }
it_should_behave_like 'a unary relation method'
it 'forwards the arguments to relation#extend' do
relation.should_receive(:extend).with(args)
subject
end
- it 'forwards the block to relation#extend' do
- relation.stub!(:extend) { |_args, proc| proc.should equal(block) }
- subject
+ unless testing_block_passing_broken?
+ it 'forwards the block to relation#extend' do
+ relation.stub!(:extend) { |_args, proc| proc.should equal(block) }
+ subject
+ end
end
end