Class: Cucumber::Ast::Filter
Instance Method Summary collapse
-
#initialize(options) ⇒ Filter
constructor
A new instance of Filter.
- #matched?(node) ⇒ Boolean
- #matched_by_scenario_names?(node) ⇒ Boolean
- #matched_by_tags?(node) ⇒ Boolean
Constructor Details
#initialize(options) ⇒ Filter
Returns a new instance of Filter.
4 5 6 |
# File 'lib/cucumber/ast/filter.rb', line 4 def initialize() @options = end |
Instance Method Details
#matched?(node) ⇒ Boolean
8 9 10 11 |
# File 'lib/cucumber/ast/filter.rb', line 8 def matched?(node) (node) && matched_by_scenario_names?(node) end |
#matched_by_scenario_names?(node) ⇒ Boolean
17 18 19 |
# File 'lib/cucumber/ast/filter.rb', line 17 def matched_by_scenario_names?(node) @options[:scenario_names].empty? || node.matches_scenario_names?(@options[:scenario_names]) end |
#matched_by_tags?(node) ⇒ Boolean
13 14 15 |
# File 'lib/cucumber/ast/filter.rb', line 13 def (node) @options[:tags].empty? || node.tagged_with?(@options[:tags]) end |