Class: Serialbench::Runners::Base
- Inherits:
-
Object
- Object
- Serialbench::Runners::Base
- Defined in:
- lib/serialbench/runners/base.rb
Direct Known Subclasses
Instance Method Summary collapse
-
#benchmark ⇒ Object
Run benchmark.
-
#initialize(environment_config, environment_config_path) ⇒ Base
constructor
A new instance of Base.
- #prepare ⇒ Object
Constructor Details
#initialize(environment_config, environment_config_path) ⇒ Base
Returns a new instance of Base.
13 14 15 16 17 18 19 20 |
# File 'lib/serialbench/runners/base.rb', line 13 def initialize(environment_config, environment_config_path) @environment_config = environment_config @environment_config_path = environment_config_path raise 'environment_config is required' unless @environment_config raise 'environment_config_path is required' unless @environment_config_path raise 'environment_config_path must be a valid file' unless File.exist?(@environment_config_path) end |
Instance Method Details
#benchmark ⇒ Object
Run benchmark
27 28 29 |
# File 'lib/serialbench/runners/base.rb', line 27 def benchmark raise NotImplementedError, 'Subclasses must implement the benchmark method' end |
#prepare ⇒ Object
22 23 24 |
# File 'lib/serialbench/runners/base.rb', line 22 def prepare raise NotImplementedError, 'Subclasses must implement the prepare method' end |