Permalink
Browse files

Modify assert conditions not to be affected

by each database bind variable naming conventions
  • Loading branch information...
1 parent 6dd0b72 commit 317868d0bd0802d48f29422ce00b8dcddea8ea31 @yahonda yahonda committed with senny May 6, 2014
Showing with 3 additions and 2 deletions.
  1. +3 −2 activerecord/test/cases/relation/merging_test.rb
@@ -17,8 +17,9 @@ def test_relation_merging
end
def test_relation_to_sql
- sql = Post.first.comments.to_sql
- assert_no_match(/\?/, sql)
+ post = Post.first
+ sql = post.comments.to_sql
+ assert_match(/.?post_id.? = #{post.id}\Z/i, sql)
end
def test_relation_merging_with_arel_equalities_keeps_last_equality

0 comments on commit 317868d

Please sign in to comment.