Skip to content

Commit 6b36deb

Browse files
p-datadogp
andauthored
avoid a warning in test suite (#4687)
2025-05-23T20:57:17.7367220Z /Users/runner/work/dd-trace-rb/dd-trace-rb/spec/spec_helper.rb:174: warning: instance variable @caller not initialized Co-authored-by: Oleg Pudeyev <[email protected]>
1 parent 8b78ef4 commit 6b36deb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

spec/spec_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@
171171
# Exclude acceptable background threads
172172
background_threads = Thread.list.reject do |t|
173173
group_name = t.group.instance_variable_get(:@group_name) if t.group.instance_variable_defined?(:@group_name)
174-
caller = t.instance_variable_get(:@caller) || []
174+
caller = t.instance_variable_defined?(:@caller) && t.instance_variable_get(:@caller) || []
175175
backtrace = t.backtrace || []
176176

177177
# Current thread

0 commit comments

Comments
 (0)