lib/parallel_tests/gherkin/runner.rb in parallel_tests-0.16.16 vs lib/parallel_tests/gherkin/runner.rb in parallel_tests-0.16.17
- old
+ new
@@ -7,10 +7,12 @@
class << self
def run_tests(test_files, process_number, num_processes, options)
sanitized_test_files = test_files.map { |val| WINDOWS ? "\"#{val}\"" : Shellwords.escape(val) }
- options = options.merge(:env => {"AUTOTEST" => "1"}) if $stdout.tty? # display color when we are in a terminal
+ options[:env] ||= {}
+ options[:env] = options[:env].merge({"AUTOTEST" => "1"}) if $stdout.tty? # display color when we are in a terminal
+
cmd = [
executable,
(runtime_logging if File.directory?(File.dirname(runtime_log))),
cucumber_opts(options[:test_options]),
*sanitized_test_files