diff options
author | Neeraj Singh <neerajdotname@gmail.com> | 2013-07-30 20:51:44 +0530 |
---|---|---|
committer | Neeraj Singh <neerajdotname@gmail.com> | 2013-07-30 20:51:44 +0530 |
commit | 389e9fe9cfab6587a554a48087c400a383a96550 (patch) | |
tree | 42ea85091d09241f9abfa8d752111fe19cab475c /activerecord/test | |
parent | 9c9a5a67bc260358172a1cacb22ec787d59ba39b (diff) | |
download | rails-389e9fe9cfab6587a554a48087c400a383a96550.tar.gz rails-389e9fe9cfab6587a554a48087c400a383a96550.tar.bz2 rails-389e9fe9cfab6587a554a48087c400a383a96550.zip |
assert_no_queries should ignore certain sqls
postgresql test if randomly executed then executes "SHOW max_identifier_length". Hence
the need to ignore certain predefined sqls that deal with system calls.
Diffstat (limited to 'activerecord/test')
-rw-r--r-- | activerecord/test/cases/associations/nested_through_associations_test.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/activerecord/test/cases/associations/nested_through_associations_test.rb b/activerecord/test/cases/associations/nested_through_associations_test.rb index e75d43bda8..9b1abc3b81 100644 --- a/activerecord/test/cases/associations/nested_through_associations_test.rb +++ b/activerecord/test/cases/associations/nested_through_associations_test.rb @@ -186,7 +186,9 @@ class NestedThroughAssociationsTest < ActiveRecord::TestCase members = assert_queries(4) { Member.includes(:organization_member_details_2).to_a.sort_by(&:id) } groucho_details, other_details = member_details(:groucho), member_details(:some_other_guy) - assert_no_queries do + # postgresql test if randomly executed then executes "SHOW max_identifier_length". Hence + # the need to ignore certain predefined sqls that deal with system calls. + assert_no_queries(ignore_none: false) do assert_equal [groucho_details, other_details], members.first.organization_member_details_2.sort_by(&:id) end end |