Class: Cucumber::StepDefinitions
- Inherits:
-
Object
- Object
- Cucumber::StepDefinitions
- Defined in:
- lib/cucumber/step_definitions.rb
Instance Method Summary collapse
-
#initialize(configuration = Configuration.default) ⇒ StepDefinitions
constructor
A new instance of StepDefinitions.
- #to_json(obj = nil) ⇒ Object
Constructor Details
#initialize(configuration = Configuration.default) ⇒ StepDefinitions
Returns a new instance of StepDefinitions.
5 6 7 8 9 |
# File 'lib/cucumber/step_definitions.rb', line 5 def initialize(configuration = Configuration.default) configuration = Configuration.new(configuration) @support_code = Runtime::SupportCode.new(nil, configuration) @support_code.load_files_from_paths(configuration.autoload_code_paths) end |
Instance Method Details
#to_json(obj = nil) ⇒ Object
11 12 13 |
# File 'lib/cucumber/step_definitions.rb', line 11 def to_json(obj = nil) @support_code.step_definitions.map(&:to_hash).to_json(obj) end |