Permalink
Browse files

Use proc instead of lambda when the blocks don't accept args

  • Loading branch information...
1 parent 3fa8a40 commit 96b22b4b3a42e4bc8428cd44ce6781292943fbc5 @dkubb dkubb committed May 25, 2010
Showing with 2 additions and 2 deletions.
  1. +1 −1 spec/unit/sql/table_creator_spec.rb
  2. +1 −1 spec/unit/sql/table_modifier_spec.rb
@@ -26,7 +26,7 @@
end
it 'should evaluate the given block' do
- block = lambda { column :foo, :bar }
+ block = proc { column :foo, :bar }
col = mock('column')
SQL::TableCreator::Column.should_receive(:new).with(@adapter, :foo, :bar, {}).and_return(col)
tc = SQL::TableCreator.new(@adapter, 'users', {}, &block)
@@ -26,7 +26,7 @@
end
it 'should evaluate the given block' do
- block = lambda { column :foo, :bar }
+ block = proc { column :foo, :bar }
col = mock('column')
SQL::TableCreator::Column.should_receive(:new).with(@adapter, :foo, :bar, {}).and_return(col)
tc = SQL::TableCreator.new(@adapter, 'users', {}, &block)

0 comments on commit 96b22b4

Please sign in to comment.