Module: Cucumber::Parser::Feature::ScenarioOutline1

Defined in:
lib/cucumber/parser/feature.rb

Instance Method Summary collapse

Instance Method Details

#at_line?(line) ⇒ Boolean

Returns:

  • (Boolean)


831
832
833
834
835
# File 'lib/cucumber/parser/feature.rb', line 831

def at_line?(line)
  outline_at_line?(line) ||
  examples_sections.at_line?(line) ||
  tags.at_line?(line)
end

#build(background, filter) ⇒ Object



860
861
862
863
864
865
866
867
868
869
870
871
# File 'lib/cucumber/parser/feature.rb', line 860

def build(background, filter)
  Ast::ScenarioOutline.new(
    background,
    comment.build, 
    tags.build,
    scenario_outline_keyword.line, 
    scenario_outline_keyword.text_value, 
    name.build, 
    steps.build, 
    examples_sections.build(filter, self)
  )
end

#has_all_tags?(tag_names) ⇒ Boolean

Returns:

  • (Boolean)


847
848
849
850
# File 'lib/cucumber/parser/feature.rb', line 847

def has_all_tags?(tag_names)
  feature_tags = self.parent.parent.tags
  tags.has_all_tags?(tag_names) || feature_tags.has_all_tags?(tag_names)
end

#has_tags?(tag_names) ⇒ Boolean

Returns:

  • (Boolean)


842
843
844
845
# File 'lib/cucumber/parser/feature.rb', line 842

def has_tags?(tag_names)
  feature_tags = self.parent.parent.tags
  tags.has_tags?(tag_names) || feature_tags.has_tags?(tag_names)
end

#matches_name?(regexp_to_match) ⇒ Boolean

Returns:

  • (Boolean)


852
853
854
# File 'lib/cucumber/parser/feature.rb', line 852

def matches_name?(regexp_to_match)
  outline_matches_name?(regexp_to_match) || examples_sections.matches_name?(regexp_to_match)
end

#outline_at_line?(line) ⇒ Boolean

Returns:

  • (Boolean)


837
838
839
840
# File 'lib/cucumber/parser/feature.rb', line 837

def outline_at_line?(line)
  scenario_outline_keyword.line == line ||
  steps.at_line?(line)
end

#outline_matches_name?(regexp_to_match) ⇒ Boolean

Returns:

  • (Boolean)


856
857
858
# File 'lib/cucumber/parser/feature.rb', line 856

def outline_matches_name?(regexp_to_match)
  name.build =~ regexp_to_match
end