Method: OpenC3::SuiteResults#start

Defined in:
lib/openc3/script/suite_results.rb

#start(test_type, test_suite_class, test_class = nil, test_case = nil, settings = nil) ⇒ Object



34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# File 'lib/openc3/script/suite_results.rb', line 34

def start(test_type, test_suite_class, test_class = nil, test_case = nil, settings = nil)
  @results = []
  @start_time = Time.now.sys
  @settings = settings
  @report = []

  if test_case
    # Executing a single test case
    @context = "#{test_suite_class.name}:#{test_class.name}:#{test_case} #{test_type}"
  elsif test_class
    # Executing an entire test
    @context = "#{test_suite_class.name}:#{test_class.name} #{test_type}"
  else
    # Executing a test suite
    @context = "#{test_suite_class.name} #{test_type}"
  end

  header()
end