diff options
Diffstat (limited to 'spec/arel/nodes/select_core_spec.rb')
-rw-r--r-- | spec/arel/nodes/select_core_spec.rb | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/spec/arel/nodes/select_core_spec.rb b/spec/arel/nodes/select_core_spec.rb index 30927abea6..d2e87c2c23 100644 --- a/spec/arel/nodes/select_core_spec.rb +++ b/spec/arel/nodes/select_core_spec.rb @@ -9,15 +9,13 @@ describe Arel::Nodes::SelectCore do core.instance_variable_set "@wheres", %w[g h i] [:froms, :projections, :wheres].each do |array_attr| - core.send(array_attr).each_with_index do |o, j| - o.should_receive(:clone).and_return("#{o}#{j}") - end + core.send(array_attr).should_receive(:clone).and_return([array_attr]) end dolly = core.clone - check dolly.froms.should == %w[a0 b1 c2] - check dolly.projections.should == %w[d0 e1 f2] - check dolly.wheres.should == %w[g0 h1 i2] + check dolly.froms.should == [:froms] + check dolly.projections.should == [:projections] + check dolly.wheres.should == [:wheres] end end end |