diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2012-07-18 13:32:21 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2012-07-18 13:32:21 -0700 |
commit | e482100d6ed022d00ba31c6c4377f6f947173337 (patch) | |
tree | 13375bfe5053efb1bd8d0895e5bd6b9a57219ad3 | |
parent | fe5b943d9fd389f313dd87bf73b7c11b8746227b (diff) | |
download | rails-e482100d6ed022d00ba31c6c4377f6f947173337.tar.gz rails-e482100d6ed022d00ba31c6c4377f6f947173337.tar.bz2 rails-e482100d6ed022d00ba31c6c4377f6f947173337.zip |
Revert "Merge pull request #7084 from LTe/logger_default_separator"
This reverts commit c08f30ff5fcda7e07cd9275a073acb2091e4b3f7, reversing
changes made to e243a8a32eb4c8777f07ca4b974bd7e38d9477d3.
-rw-r--r-- | activesupport/lib/active_support/tagged_logging.rb | 2 | ||||
-rw-r--r-- | activesupport/test/tagged_logging_test.rb | 15 |
2 files changed, 3 insertions, 14 deletions
diff --git a/activesupport/lib/active_support/tagged_logging.rb b/activesupport/lib/active_support/tagged_logging.rb index 974c42ebba..5e080df518 100644 --- a/activesupport/lib/active_support/tagged_logging.rb +++ b/activesupport/lib/active_support/tagged_logging.rb @@ -31,7 +31,7 @@ module ActiveSupport def tags_text tags = current_tags if tags.any? - tags.collect { |tag| "[#{tag}] " }.join('') + tags.collect { |tag| "[#{tag}] " }.join end end end diff --git a/activesupport/test/tagged_logging_test.rb b/activesupport/test/tagged_logging_test.rb index 732a28c56f..0751c2469e 100644 --- a/activesupport/test/tagged_logging_test.rb +++ b/activesupport/test/tagged_logging_test.rb @@ -10,13 +10,8 @@ class TaggedLoggingTest < ActiveSupport::TestCase end setup do - @output = StringIO.new - @logger = ActiveSupport::TaggedLogging.new(MyLogger.new(@output)) - @separator = $, - end - - after do - $, = @separator + @output = StringIO.new + @logger = ActiveSupport::TaggedLogging.new(MyLogger.new(@output)) end test "tagged once" do @@ -74,10 +69,4 @@ class TaggedLoggingTest < ActiveSupport::TestCase assert_equal "[BCX] [Jason] Funky time\n[BCX] Junky time!\n", @output.string end - - test "using the correct separator" do - $, = "_" - @logger.tagged("BCX", "BDX") { @logger.info "Funky time" } - assert_equal "[BCX] [BDX] Funky time\n", @output.string - end end |