Class: CucumberAnalytics::Tag
- Inherits:
-
Object
- Object
- CucumberAnalytics::Tag
- Includes:
- Nested, Raw, Sourceable
- Defined in:
- lib/cucumber_analytics/tag.rb
Overview
A class modeling a Tag.
Instance Attribute Summary collapse
-
#name ⇒ Object
The name of the Tag.
Attributes included from Nested
Attributes included from Sourceable
Attributes included from Raw
Instance Method Summary collapse
-
#initialize(source = nil) ⇒ Tag
constructor
Creates a new Tag object and, if source is provided, populates the object.
-
#to_s ⇒ Object
Returns gherkin representation of the tag.
Methods included from Nested
Constructor Details
#initialize(source = nil) ⇒ Tag
Creates a new Tag object and, if source is provided, populates the object.
18 19 20 21 22 |
# File 'lib/cucumber_analytics/tag.rb', line 18 def initialize(source = nil) parsed_tag = process_source(source) build_tag(parsed_tag) if parsed_tag end |
Instance Attribute Details
#name ⇒ Object
The name of the Tag
13 14 15 |
# File 'lib/cucumber_analytics/tag.rb', line 13 def name @name end |
Instance Method Details
#to_s ⇒ Object
Returns gherkin representation of the tag.
25 26 27 |
# File 'lib/cucumber_analytics/tag.rb', line 25 def to_s name || '' end |