Class: Kitchen::Transport::Runtests::Connection

Inherits:
Kitchen::Transport::Rsync::Connection
  • Object
show all
Defined in:
lib/kitchen/transport/runtests.rb

Instance Method Summary collapse

Instance Method Details

#execute_with_exit_code(command) ⇒ Object



8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# File 'lib/kitchen/transport/runtests.rb', line 8

def execute_with_exit_code(command)
  if command.start_with?("sh -c")
    super
  else
     = ()
    cmd = [
      .instance_variable_get("@command"),
      .instance_variable_get("@arguments").join(' '),
      '--',
      command.shellescape,
    ].join(' ')
    system(cmd)
    $?.exitstatus
  end
end