Class: TestCenter::Helper::MultiScanManager::TestBatchWorker

Inherits:
Object
  • Object
show all
Defined in:
lib/fastlane/plugin/test_center/helper/multi_scan_manager/test_batch_worker.rb

Direct Known Subclasses

ParallelTestBatchWorker

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ TestBatchWorker

Returns a new instance of TestBatchWorker.



7
8
9
10
# File 'lib/fastlane/plugin/test_center/helper/multi_scan_manager/test_batch_worker.rb', line 7

def initialize(options)
  @options = options
  @state = :ready_to_work
end

Instance Attribute Details

#stateObject

Returns the value of attribute state.



5
6
7
# File 'lib/fastlane/plugin/test_center/helper/multi_scan_manager/test_batch_worker.rb', line 5

def state
  @state
end

Instance Method Details

#process_resultsObject



12
13
14
# File 'lib/fastlane/plugin/test_center/helper/multi_scan_manager/test_batch_worker.rb', line 12

def process_results
  @state = :ready_to_work
end

#run(run_options) ⇒ Object



16
17
18
19
20
21
22
# File 'lib/fastlane/plugin/test_center/helper/multi_scan_manager/test_batch_worker.rb', line 16

def run(run_options)
  self.state = :working
  test_batch_worker_final_result = RetryingScan.run(@options.merge(run_options))
  @options[:test_batch_results] << test_batch_worker_final_result
  self.state = :ready_to_work
  test_batch_worker_final_result
end