Sha256: 97821c4589e39165619f99f1e45dc5798f2fa3980323ca7f32b205cea746eaf6
Contents?: true
Size: 1.3 KB
Versions: 2
Compression:
Stored size: 1.3 KB
Contents
require 'cucumber/core/ast/location' require 'cucumber/core/ast/describes_itself' require 'cucumber/core/ast/step' module Cucumber module Core module Ast class OutlineStep include HasLocation include DescribesItself attr_reader :language, :location, :keyword, :name, :multiline_arg def initialize(language, location, keyword, name, multiline_arg) @language, @location, @keyword, @name, @multiline_arg = language, location, keyword, name, multiline_arg @language || raise("Language is required!") @gherkin_statement = nil end def gherkin_statement(node = nil) @gherkin_statement ||= node end def to_step(row) step = Ast::Step.new(language, location, keyword, row.expand(name), replace_multiline_arg(row)) step.gherkin_statement(@gherkin_statement) step end private def description_for_visitors :outline_step end def children # TODO remove duplication with Step # TODO spec [@multiline_arg] end def replace_multiline_arg(example_row) return unless multiline_arg multiline_arg.map { |cell| example_row.expand(cell) } end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
cucumber-core-1.0.0.beta.2 | lib/cucumber/core/ast/outline_step.rb |
cucumber-core-1.0.0.beta.1 | lib/cucumber/core/ast/outline_step.rb |