Class: 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 ⇒ Object
Constructor Details
#initialize(configuration = Configuration.default) ⇒ StepDefinitions
Returns a new instance of StepDefinitions.
4 5 6 7 8 |
# File 'lib/cucumber/step_definitions.rb', line 4 def initialize(configuration = Configuration.default) configuration = Configuration.parse(configuration) @support_code = Runtime::SupportCode.new(nil, false) @support_code.load_files_from_paths(configuration.autoload_code_paths) end |
Instance Method Details
#to_json ⇒ Object
10 11 12 |
# File 'lib/cucumber/step_definitions.rb', line 10 def to_json @support_code.step_definitions.map{|stepdef| stepdef.to_hash}.to_json end |