aboutsummaryrefslogtreecommitdiffstats
path: root/spec
diff options
context:
space:
mode:
Diffstat (limited to 'spec')
-rw-r--r--spec/arel/attributes/attribute_spec.rb17
1 files changed, 17 insertions, 0 deletions
diff --git a/spec/arel/attributes/attribute_spec.rb b/spec/arel/attributes/attribute_spec.rb
new file mode 100644
index 0000000000..5599bb7b51
--- /dev/null
+++ b/spec/arel/attributes/attribute_spec.rb
@@ -0,0 +1,17 @@
+require 'spec_helper'
+
+module Arel
+ module Attributes
+ describe 'attribute' do
+ describe '#eq' do
+ it 'should return an equality node' do
+ attribute = Attribute.new nil, nil, nil
+ equality = attribute.eq 1
+ equality.left.should == attribute
+ equality.right.should == 1
+ equality.should be_kind_of Nodes::Equality
+ end
+ end
+ end
+ end
+end