mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-12-24 20:01:53 +00:00
Tests: output commands if $DEBUG is set
This commit is contained in:
parent
3b56ac1f15
commit
8a6533dbcd
@ -249,6 +249,7 @@ class SimpleTest
|
||||
command << " >#{temp_file.path} 2>&1 "
|
||||
end
|
||||
|
||||
puts "COMMAND #{command}" if ENV['DEBUG']
|
||||
self.error "system command failed: #{command} (#{$? >> 8})" if !system(command) && (options[:exit_code] != ($? >> 8))
|
||||
|
||||
return IO.readlines(temp_file.path) if temp_file
|
||||
|
@ -64,6 +64,7 @@ class Test
|
||||
@debug_commands << command
|
||||
command << " >/dev/null 2>/dev/null " unless (/>/.match(command))
|
||||
|
||||
puts "COMMAND #{command}" if ENV['DEBUG']
|
||||
error "system command failed: #{command} (" + ($? >> 8).to_s + ")" if !system(command) && ((arg.size == 0) || ((arg[0] << 8) != $?))
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user