class Gherkin::Formatter::Model::Step
Attributes
doc_string[R]
rows[R]
Public Class Methods
new(comments, keyword, name, line, rows, doc_string)
click to toggle source
Calls superclass method
Gherkin::Formatter::Model::BasicStatement.new
# File lib/gherkin/formatter/model.rb, line 134 def initialize(comments, keyword, name, line, rows, doc_string) super(comments, keyword, name, line) @rows, @doc_string = rows, doc_string end
Public Instance Methods
line_range()
click to toggle source
Calls superclass method
Gherkin::Formatter::Model::BasicStatement#line_range
# File lib/gherkin/formatter/model.rb, line 139 def line_range range = super if(rows) range = range.first..rows[-1].line elsif(doc_string) range = range.first..doc_string.line_range.last end range end
outline_args()
click to toggle source
# File lib/gherkin/formatter/model.rb, line 153 def outline_args offset = 0 name.scan(/<[^<]*>/).map do |val| offset = name.index(val, offset) Argument.new(offset, val) end end
replay(formatter)
click to toggle source
# File lib/gherkin/formatter/model.rb, line 149 def replay(formatter) formatter.step(self) end