Sha256: a37f47fb70675b9ca071892d0bee98ec6c09d23fe42a6f833ceed6e540064f14
Contents?: true
Size: 774 Bytes
Versions: 3
Compression:
Stored size: 774 Bytes
Contents
# frozen_string_literal: true require 'childprocess' module NoradBeacon class MultiRunner < Runner attr_reader :result_sets # Initialize an instance of the MultiRunner class # # @param prog [String] the program to execute # @param args [Array] list of arguments to pass to the program # @param timeout [Fixnum] optionally specify the timeout for the sub process # @return [NoradBeacon::Runner] an instance of the Runner class def initialize(prog, args, timeout = 600) raise ArgumentError, 'args must be an Array' unless args.is_a?(Array) @prog = prog @timeout = timeout @results_file = "/tmp/#{@prog}.#{Time.now.strftime('%Y%m%d-%H%M%S')}" @result_sets = [] @args = format_args(args) end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
norad_beacon-0.1.3 | lib/norad_beacon/multi_runner.rb |
norad_beacon-0.1.2 | lib/norad_beacon/multi_runner.rb |
norad_beacon-0.1.1 | lib/norad_beacon/multi_runner.rb |