diff options
author | Emilio Tagua <miloops@gmail.com> | 2010-02-17 11:50:03 -0300 |
---|---|---|
committer | Emilio Tagua <miloops@gmail.com> | 2010-02-17 11:50:03 -0300 |
commit | f37c4a4d690888aa5cf8e54c8b404dd10f219f46 (patch) | |
tree | 50e08f7d00ccbd55910f0ecc30ad182dc34cb303 /spec | |
parent | 0c2930cba355607eebb8ead19161a41ec0cec992 (diff) | |
download | rails-f37c4a4d690888aa5cf8e54c8b404dd10f219f46.tar.gz rails-f37c4a4d690888aa5cf8e54c8b404dd10f219f46.tar.bz2 rails-f37c4a4d690888aa5cf8e54c8b404dd10f219f46.zip |
Fix test which depends on the RUBY_VERSION when using sqlite3 adapter.
Diffstat (limited to 'spec')
-rw-r--r-- | spec/arel/engines/sql/unit/predicates/in_spec.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/spec/arel/engines/sql/unit/predicates/in_spec.rb b/spec/arel/engines/sql/unit/predicates/in_spec.rb index a8ae9e4b5f..a1c42f714e 100644 --- a/spec/arel/engines/sql/unit/predicates/in_spec.rb +++ b/spec/arel/engines/sql/unit/predicates/in_spec.rb @@ -99,7 +99,11 @@ module Arel end adapter_is :sqlite3 do - sql.should be_like(%Q{"developers"."created_at" BETWEEN '2010-01-01 00:00:00' AND '2010-02-01 00:00:00'}) + if RUBY_VERSION < '1.9' + sql.should be_like(%Q{"developers"."created_at" BETWEEN '2010-01-01 00:00:00.000000' AND '2010-02-01 00:00:00.000000'}) + else + sql.should be_like(%Q{"developers"."created_at" BETWEEN '2010-01-01 00:00:00' AND '2010-02-01 00:00:00'}) + end end adapter_is :postgresql do |