diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-09-24 15:21:54 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-09-24 15:21:54 -0700 |
commit | 6b86ae4f9f2fb8cd145f958753fedf16aae3a0d4 (patch) | |
tree | fff66461830df50e3211d8ced131584e6d75f9d4 /spec/activerecord_compat_spec.rb | |
parent | 245d797a8ccab3ed2de9a0eedf455d3094a091ce (diff) | |
download | rails-6b86ae4f9f2fb8cd145f958753fedf16aae3a0d4.tar.gz rails-6b86ae4f9f2fb8cd145f958753fedf16aae3a0d4.tar.bz2 rails-6b86ae4f9f2fb8cd145f958753fedf16aae3a0d4.zip |
shuffling around the spec directory
Diffstat (limited to 'spec/activerecord_compat_spec.rb')
-rw-r--r-- | spec/activerecord_compat_spec.rb | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/spec/activerecord_compat_spec.rb b/spec/activerecord_compat_spec.rb new file mode 100644 index 0000000000..a7eeb7e5ee --- /dev/null +++ b/spec/activerecord_compat_spec.rb @@ -0,0 +1,18 @@ +require 'spec_helper' + +module Arel + describe 'activerecord compatibility' do + describe 'select manager' do + it 'provides wheres' do + table = Table.new :users + manager = Arel::SelectManager.new Table.engine + manager.where table[:id].eq 1 + manager.where table[:name].eq 'Aaron' + + check manager.wheres.map { |x| + x.value + }.join(', ').should == "\"users\".\"id\" = 1, \"users\".\"name\" = 'Aaron'" + end + end + end +end |