From e1bb9fc671a8d33fb70f94f094bc5644e9c81a18 Mon Sep 17 00:00:00 2001 From: Arthur Neves Date: Wed, 25 Sep 2013 19:50:42 -0400 Subject: on tests: dont always touch firm on validate --- activerecord/test/cases/associations/has_many_associations_test.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'activerecord/test/cases') diff --git a/activerecord/test/cases/associations/has_many_associations_test.rb b/activerecord/test/cases/associations/has_many_associations_test.rb index 0a35012e67..eec78f95c5 100644 --- a/activerecord/test/cases/associations/has_many_associations_test.rb +++ b/activerecord/test/cases/associations/has_many_associations_test.rb @@ -656,7 +656,9 @@ class HasManyAssociationsTest < ActiveRecord::TestCase def test_inverse_on_before_validate firm = companies(:first_firm) assert_queries(1) do - firm.clients_of_firm << Client.new("name" => "Natural Company") + client = Client.new("name" => "Natural Company") + client.touch_firm_on_validate = true + firm.clients_of_firm << client end end -- cgit v1.2.3