Method: Cucumber::StepMatch#initialize

Defined in:
lib/cucumber/step_match.rb

#initialize(step_definition, name_to_match, name_to_report, step_arguments) ⇒ StepMatch

Creates a new StepMatch. The name_to_report argument is what’s reported, unless it’s is, in which case name_to_report is used instead.



8
9
10
11
12
# File 'lib/cucumber/step_match.rb', line 8

def initialize(step_definition, name_to_match, name_to_report, step_arguments)
  raise "name_to_match can't be nil" if name_to_match.nil?
  raise "step_arguments can't be nil (but it can be an empty array)" if step_arguments.nil?
  @step_definition, @name_to_match, @name_to_report, @step_arguments = step_definition, name_to_match, name_to_report, step_arguments
end