aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/tagged_logging_test.rb
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2016-08-06 18:03:25 +0200
committerXavier Noria <fxn@hashref.com>2016-08-06 18:10:53 +0200
commita731125f12c5834de7eae3455fad63ea4d348034 (patch)
tree0ada76c652c1a2a1fd68cdbecf5adc2df6beeb51 /activesupport/test/tagged_logging_test.rb
parentd66e7835bea9505f7003e5038aa19b6ea95ceea1 (diff)
downloadrails-a731125f12c5834de7eae3455fad63ea4d348034.tar.gz
rails-a731125f12c5834de7eae3455fad63ea4d348034.tar.bz2
rails-a731125f12c5834de7eae3455fad63ea4d348034.zip
applies new string literal convention in activesupport/test
The current code base is not uniform. After some discussion, we have chosen to go with double quotes by default.
Diffstat (limited to 'activesupport/test/tagged_logging_test.rb')
-rw-r--r--activesupport/test/tagged_logging_test.rb18
1 files changed, 9 insertions, 9 deletions
diff --git a/activesupport/test/tagged_logging_test.rb b/activesupport/test/tagged_logging_test.rb
index 917fa46c96..2469e827d4 100644
--- a/activesupport/test/tagged_logging_test.rb
+++ b/activesupport/test/tagged_logging_test.rb
@@ -1,6 +1,6 @@
-require 'abstract_unit'
-require 'active_support/logger'
-require 'active_support/tagged_logging'
+require "abstract_unit"
+require "active_support/logger"
+require "active_support/tagged_logging"
class TaggedLoggingTest < ActiveSupport::TestCase
class MyLogger < ::ActiveSupport::Logger
@@ -14,7 +14,7 @@ class TaggedLoggingTest < ActiveSupport::TestCase
@logger = ActiveSupport::TaggedLogging.new(MyLogger.new(@output))
end
- test 'sets logger.formatter if missing and extends it with a tagging API' do
+ test "sets logger.formatter if missing and extends it with a tagging API" do
logger = Logger.new(StringIO.new)
assert_nil logger.formatter
ActiveSupport::TaggedLogging.new(logger)
@@ -43,14 +43,14 @@ class TaggedLoggingTest < ActiveSupport::TestCase
end
test "push and pop tags directly" do
- assert_equal %w(A B C), @logger.push_tags('A', ['B', ' ', ['C']])
- @logger.info 'a'
+ assert_equal %w(A B C), @logger.push_tags("A", ["B", " ", ["C"]])
+ @logger.info "a"
assert_equal %w(C), @logger.pop_tags
- @logger.info 'b'
+ @logger.info "b"
assert_equal %w(B), @logger.pop_tags(1)
- @logger.info 'c'
+ @logger.info "c"
assert_equal [], @logger.clear_tags!
- @logger.info 'd'
+ @logger.info "d"
assert_equal "[A] [B] [C] a\n[A] [B] b\n[A] c\nd\n", @output.string
end