Skip to content

Commit 7889abb

Browse files
committed
[traceId] update rails tests for assertion that 'Message' is logged
[AO-12305]
1 parent 4b22fde commit 7889abb

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

test/frameworks/rails_logger_formatter_test.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
@logger = ActiveSupport::Logger.new(out)
88
end
99

10-
let (:msg) { @logger.warn "Checking"; @in.gets }
10+
let (:msg) { @logger.warn "Message"; @in.gets }
1111
let (:exc_message) { @logger.warn StandardError.new ; @in.gets }
1212

1313
load File.join(File.dirname(File.dirname(__FILE__)), 'instrumentation', 'logger_formatter_helper.rb')
@@ -19,7 +19,7 @@
1919
@logger = ActiveSupport::TaggedLogging.new(Logger.new(out))
2020
end
2121

22-
let (:msg) { @logger.tagged('test', 'tag') { @logger.warn "Checking" }; @in.gets }
22+
let (:msg) { @logger.tagged('check', 'tag') { @logger.warn "Message" }; @in.gets }
2323
let (:exc_message) { @logger.warn StandardError.new ; @in.gets }
2424

2525
load File.join(File.dirname(File.dirname(__FILE__)), 'instrumentation', 'logger_formatter_helper.rb')
@@ -33,7 +33,7 @@
3333

3434
let(:log_output) { StringIO.new }
3535
let(:logger) { Logger.new(log_output) }
36-
let(:subscriber) { Lograge::LogSubscribers::ActionCable.new }
36+
let(:subscriber) { Lograge::LogSubscribers::ActionController.new }
3737
let(:event_params) { { 'foo' => 'bar' } }
3838
let(:event) do
3939
ActiveSupport::Notifications::Event.new(
@@ -42,7 +42,7 @@
4242
Time.now,
4343
2,
4444
status: 200,
45-
controller: 'HomeController',
45+
controller: 'MessageController',
4646
action: 'index',
4747
format: 'application/json',
4848
method: 'GET',
@@ -54,7 +54,7 @@
5454
end
5555

5656
let (:msg) do
57-
subscriber.perform_action(event)
57+
subscriber.process_action(event)
5858
log_output.string
5959
end
6060

0 commit comments

Comments
 (0)