From c8b24cc2675aceb020a8b8c8ee46854ab30d0125 Mon Sep 17 00:00:00 2001 From: Ken Collins Date: Tue, 3 Nov 2015 19:18:56 -0500 Subject: Update docs/comments to use setup/teardown blocks vs. methods. As discussed in the minitest-spec-rails issue (http://git.io/vlHxx) Rails uses setup/teardown callbacks. Defining `setup` or `teardown` methods vs. blocks will yield inconsistent behavior in the callback chain. --- activesupport/lib/active_support/log_subscriber/test_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activesupport') diff --git a/activesupport/lib/active_support/log_subscriber/test_helper.rb b/activesupport/lib/active_support/log_subscriber/test_helper.rb index cbc20c103d..0abedafe76 100644 --- a/activesupport/lib/active_support/log_subscriber/test_helper.rb +++ b/activesupport/lib/active_support/log_subscriber/test_helper.rb @@ -10,7 +10,7 @@ module ActiveSupport # class SyncLogSubscriberTest < ActiveSupport::TestCase # include ActiveSupport::LogSubscriber::TestHelper # - # def setup + # setup do # super # ActiveRecord::LogSubscriber.attach_to(:active_record) # end -- cgit v1.2.3 From 91f5adf03aaf5347c694d901a81c25ee40525497 Mon Sep 17 00:00:00 2001 From: Ken Collins Date: Wed, 4 Nov 2015 11:15:51 -0500 Subject: Update docs/comments to use setup/teardown blocks vs. methods. * Remove super for setup block. Not needed. --- activesupport/lib/active_support/log_subscriber/test_helper.rb | 1 - 1 file changed, 1 deletion(-) (limited to 'activesupport') diff --git a/activesupport/lib/active_support/log_subscriber/test_helper.rb b/activesupport/lib/active_support/log_subscriber/test_helper.rb index 0abedafe76..588ed67c81 100644 --- a/activesupport/lib/active_support/log_subscriber/test_helper.rb +++ b/activesupport/lib/active_support/log_subscriber/test_helper.rb @@ -11,7 +11,6 @@ module ActiveSupport # include ActiveSupport::LogSubscriber::TestHelper # # setup do - # super # ActiveRecord::LogSubscriber.attach_to(:active_record) # end # -- cgit v1.2.3