23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
# File 'lib/plugins/inspec-parallel/lib/inspec-parallel/runner.rb', line 23
def run
initiate_background_run if run_in_background
original_stdout_stream = ChefLicensing::Config.output
until invocations.empty? && @child_tracker.empty?
ChefLicensing::Config.output = STDERR
while should_start_more_jobs?
if Inspec.locally_windows?
spawn_another_process
else
fork_another_process
end
end
update_ui_poll_select
cleanup_child_processes
sleep 0.1
end
ChefLicensing::Config.output = original_stdout_stream
rename_error_log_files if Inspec.locally_windows?
cleanup_empty_error_log_files
cleanup_daemon_process if run_in_background
end
|