2
require 'cucumber/ast/feature_factory'
7
it "has a step_count" do
8
parse_feature(<<-GHERKIN)
33
features.step_count.should == (2 + 3) + (3 * (2 + 2))
36
def parse_feature(gherkin)
37
path = 'features/test.feature'
38
builder = Cucumber::Parser::GherkinBuilder.new(path)
39
parser = Gherkin::Parser::Parser.new(builder, true, "root", false)
40
parser.parse(gherkin, path, 0)
41
builder.language = parser.i18n_language
42
feature = builder.result
43
features.add_feature(feature)
46
let(:features) { Features.new }