Module: OrigenTesters::Flow

Defined in:
lib/test_ids/origen_testers/flow.rb

Constant Summary collapse

BIN_OPTS =
%i(bin softbin bin_size softbin_size number number_size).freeze

Instance Method Summary collapse

Instance Method Details

#_orig_testObject

Override the flow.test method to inject our generated bin and test numbers



10
# File 'lib/test_ids/origen_testers/flow.rb', line 10

alias_method :_orig_test, :test

#test(instance, options = {}) ⇒ Object



11
12
13
14
15
16
17
18
19
20
21
22
23
24
# File 'lib/test_ids/origen_testers/flow.rb', line 11

def test(instance, options = {})
  if TestIds.configured? && options[:test_ids] != :notrack
    options[:test_ids_flow_id] = try(:top_level).try(:id) || id

    TestIds.current_configuration.allocator.allocate(instance, options)

    unless TestIds.current_configuration.send_to_ate?
      BIN_OPTS.each do |opt|
        options.delete(opt)
      end
    end
  end
  _orig_test(instance, options)
end