mirror of
https://github.com/inspec/inspec
synced 2024-11-10 07:04:15 +00:00
Telemetry run context library fix - caller location handling for Ruby 3.4
Signed-off-by: Nik08 <nikita.mathur@progress.com>
This commit is contained in:
parent
2bbe8d97c0
commit
f01e4795f2
1 changed files with 5 additions and 2 deletions
|
@ -26,8 +26,11 @@ module Inspec
|
|||
end
|
||||
|
||||
def self.run_by_thor?(stack)
|
||||
stack_match(stack: stack, path: "thor/command", label: "run") &&
|
||||
stack_match(stack: stack, path: "thor/invocation", label: "invoke_command")
|
||||
# Handled in both ways to fix label differences for Ruby 3.4 and other versions of Ruby
|
||||
(stack_match(stack: stack, path: "thor/command", label: "Thor::Command#run") &&
|
||||
stack_match(stack: stack, path: "thor/invocation", label: "Thor::Invocation#invoke_command")) ||
|
||||
(stack_match(stack: stack, path: "thor/command", label: "run") &&
|
||||
stack_match(stack: stack, path: "thor/invocation", label: "invoke_command"))
|
||||
end
|
||||
|
||||
def self.kitchen?(stack)
|
||||
|
|
Loading…
Reference in a new issue