Commit 326b2a15e9f9978f085df18fde9351c1af46c800
1 parent
749e09ac
Exists in
master
and in
21 other branches
Fixed logger errors
Showing
1 changed file
with
2 additions
and
3 deletions
Show diff stats
test/test_helper.rb
... | ... | @@ -4,7 +4,6 @@ require "minitest/autorun" |
4 | 4 | require "minitest/pride" |
5 | 5 | require "logger" |
6 | 6 | require "active_support/core_ext" if defined?(NoBrainer) |
7 | -require "active_support/logger" | |
8 | 7 | require "active_support/notifications" |
9 | 8 | |
10 | 9 | ENV["RACK_ENV"] = "test" |
... | ... | @@ -12,7 +11,7 @@ ENV["RACK_ENV"] = "test" |
12 | 11 | Minitest::Test = Minitest::Unit::TestCase unless defined?(Minitest::Test) |
13 | 12 | |
14 | 13 | File.delete("elasticsearch.log") if File.exist?("elasticsearch.log") |
15 | -Searchkick.client.transport.logger = ActiveSupport::Logger.new("elasticsearch.log") | |
14 | +Searchkick.client.transport.logger = Logger.new("elasticsearch.log") | |
16 | 15 | Searchkick.search_timeout = 5 |
17 | 16 | |
18 | 17 | puts "Running against Elasticsearch #{Searchkick.server_version}" |
... | ... | @@ -20,7 +19,7 @@ puts "Running against Elasticsearch #{Searchkick.server_version}" |
20 | 19 | I18n.config.enforce_available_locales = true |
21 | 20 | |
22 | 21 | ActiveJob::Base.logger = nil if defined?(ActiveJob) |
23 | -ActiveSupport::LogSubscriber.logger = ActiveSupport::Logger.new(STDOUT) if ENV["NOTIFICATIONS"] | |
22 | +ActiveSupport::LogSubscriber.logger = Logger.new(STDOUT) if ENV["NOTIFICATIONS"] | |
24 | 23 | |
25 | 24 | def elasticsearch2? |
26 | 25 | Searchkick.server_version.starts_with?("2.") | ... | ... |