Class: OrigenTesters::SmartestBasedTester::Base::TestMethods::BaseTml
- Inherits:
-
Object
- Object
- OrigenTesters::SmartestBasedTester::Base::TestMethods::BaseTml
- Defined in:
- lib/origen_testers/smartest_based_tester/base/test_methods/base_tml.rb
Overview
Base class of all test method libraries
Instance Attribute Summary collapse
-
#test_methods ⇒ Object
readonly
Returns the test_methods object for the current flow.
Class Method Summary collapse
Instance Method Summary collapse
- #definitions ⇒ Object
-
#initialize(test_methods) ⇒ BaseTml
constructor
A new instance of BaseTml.
- #method_missing(method, *args, &block) ⇒ Object
- #platform ⇒ Object
Constructor Details
#initialize(test_methods) ⇒ BaseTml
Returns a new instance of BaseTml.
14 15 16 |
# File 'lib/origen_testers/smartest_based_tester/base/test_methods/base_tml.rb', line 14 def initialize(test_methods) @test_methods = test_methods end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object
18 19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/origen_testers/smartest_based_tester/base/test_methods/base_tml.rb', line 18 def method_missing(method, *args, &block) if definitions[method] instantiate_test_method(method, args) else method = method.to_s.underscore.to_sym if definitions[method] instantiate_test_method(method, args) else super end end end |
Instance Attribute Details
#test_methods ⇒ Object (readonly)
Returns the test_methods object for the current flow
12 13 14 |
# File 'lib/origen_testers/smartest_based_tester/base/test_methods/base_tml.rb', line 12 def test_methods @test_methods end |
Class Method Details
.test_method_classes ⇒ Object
7 8 9 |
# File 'lib/origen_testers/smartest_based_tester/base/test_methods/base_tml.rb', line 7 def self.test_method_classes @test_method_classes ||= {} end |
Instance Method Details
#definitions ⇒ Object
35 36 37 |
# File 'lib/origen_testers/smartest_based_tester/base/test_methods/base_tml.rb', line 35 def definitions @definitions || self.class::TEST_METHODS end |
#platform ⇒ Object
31 32 33 |
# File 'lib/origen_testers/smartest_based_tester/base/test_methods/base_tml.rb', line 31 def platform Origen.interface.platform end |