From b706f690b611d647aae15a85caa19d167814ae3c Mon Sep 17 00:00:00 2001 From: Emilio Tagua Date: Wed, 10 Mar 2010 18:16:07 -0300 Subject: Arel doesn't has to know if a table or column exists. --- spec/arel/algebra/unit/relations/relation_spec.rb | 3 +-- spec/arel/algebra/unit/relations/table_spec.rb | 1 - 2 files changed, 1 insertion(+), 3 deletions(-) (limited to 'spec/arel/algebra') diff --git a/spec/arel/algebra/unit/relations/relation_spec.rb b/spec/arel/algebra/unit/relations/relation_spec.rb index cf6509fe6a..a1d1793d92 100644 --- a/spec/arel/algebra/unit/relations/relation_spec.rb +++ b/spec/arel/algebra/unit/relations/relation_spec.rb @@ -16,10 +16,9 @@ module Arel end describe 'when given a', Symbol, String do - it "returns the attribute with the same name, if it exists" do + it "returns the attribute with the same name" do check @relation[:id].should == @attribute1 check @relation['id'].should == @attribute1 - @relation[:does_not_exist].should be_nil end end end diff --git a/spec/arel/algebra/unit/relations/table_spec.rb b/spec/arel/algebra/unit/relations/table_spec.rb index 19c1ba2bea..d93446f1b9 100644 --- a/spec/arel/algebra/unit/relations/table_spec.rb +++ b/spec/arel/algebra/unit/relations/table_spec.rb @@ -10,7 +10,6 @@ module Arel describe 'when given a', Symbol do it "manufactures an attribute if the symbol names an attribute within the relation" do check @relation[:id].should == Attribute.new(@relation, :id) - @relation[:does_not_exist].should be_nil end end -- cgit v1.2.3