class Koine::TestRunner::CommandExecuter
Public Instance Methods
execute(command)
click to toggle source
# File lib/koine/test_runner/command_executer.rb, line 4 def execute(command) start = Time.now system(command.to_s) finish = Time.now elapsed = finish - start logger.info("#{command} => elapsed time: #{elapsed.round(2)}") puts "\nTook #{elapsed.round(2)} seconds" $?.exitstatus end
execute_and_exit(command)
click to toggle source
# File lib/koine/test_runner/command_executer.rb, line 19 def execute_and_exit(command) puts command exit(execute(command)) end
fail(reason)
click to toggle source
# File lib/koine/test_runner/command_executer.rb, line 14 def fail(reason) puts reason exit(1) end
logger()
click to toggle source
# File lib/koine/test_runner/command_executer.rb, line 24 def logger @logger ||= Logger.new('/tmp/test_runner.log') end