From 3baace687cfbf4c98367fda31e0a4b0f85ce813f Mon Sep 17 00:00:00 2001 From: Guo Xiang Tan Date: Thu, 13 Mar 2014 21:35:58 -0700 Subject: Use teardown helper method. Follow-Up to https://github.com/rails/rails/pull/14348 Ensure that SQLCounter.clear_log is called after each test. This is a step to prevent side effects when running tests. This will allow us to run them in random order. --- activerecord/test/cases/validations/i18n_validation_test.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activerecord/test/cases/validations') diff --git a/activerecord/test/cases/validations/i18n_validation_test.rb b/activerecord/test/cases/validations/i18n_validation_test.rb index efa0c9b934..3db742c15b 100644 --- a/activerecord/test/cases/validations/i18n_validation_test.rb +++ b/activerecord/test/cases/validations/i18n_validation_test.rb @@ -14,7 +14,7 @@ class I18nValidationTest < ActiveRecord::TestCase I18n.backend.store_translations('en', :errors => {:messages => {:custom => nil}}) end - def teardown + teardown do I18n.load_path.replace @old_load_path I18n.backend = @old_backend end -- cgit v1.2.3