Method: Beaker::TestSuite#initialize
- Defined in:
- lib/beaker/test_suite.rb
#initialize(name, hosts, options, fail_mode = nil) ⇒ TestSuite
Returns a new instance of TestSuite.
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 |
# File 'lib/beaker/test_suite.rb', line 21 def initialize(name, hosts, , fail_mode = nil) @logger = [:logger] @test_cases = [] @test_files = [name] @name = name.to_s.gsub(/\s+/, '-') @hosts = hosts @run = false @options = @fail_mode = [:fail_mode] || fail_mode report_and_raise(@logger, RuntimeError.new("#{@name}: no test files found..."), "TestSuite: initialize") if @test_files.empty? @test_files = @test_files.sort rescue => e report_and_raise(@logger, e, "TestSuite: initialize") end |