Class: Gherkin::Dialect

Inherits:
Object show all
Defined in:
lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(spec) ⇒ Dialect

Returns a new instance of Dialect.



14
15
16
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 14

def initialize(spec)
  @spec = spec
end

Class Method Details

.for(name) ⇒ Object



8
9
10
11
12
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 8

def self.for(name)
  spec = DIALECTS[name]
  return nil unless spec
  new(spec)
end

Instance Method Details

#and_keywordsObject



54
55
56
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 54

def and_keywords
  @spec.fetch('and')
end

#background_keywordsObject



38
39
40
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 38

def background_keywords
  @spec.fetch('background')
end

#but_keywordsObject



58
59
60
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 58

def but_keywords
  @spec.fetch('but')
end

#examples_keywordsObject



34
35
36
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 34

def examples_keywords
  @spec.fetch('examples')
end

#feature_keywordsObject



18
19
20
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 18

def feature_keywords
  @spec.fetch('feature')
end

#given_keywordsObject



42
43
44
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 42

def given_keywords
  @spec.fetch('given')
end

#rule_keywordsObject



22
23
24
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 22

def rule_keywords
  @spec.fetch('rule')
end

#scenario_keywordsObject



26
27
28
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 26

def scenario_keywords
  @spec.fetch('scenario')
end

#scenario_outline_keywordsObject



30
31
32
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 30

def scenario_outline_keywords
  @spec.fetch('scenarioOutline')
end

#then_keywordsObject



50
51
52
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 50

def then_keywords
  @spec.fetch('then')
end

#when_keywordsObject



46
47
48
# File 'lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/cucumber-gherkin-23.0.1/lib/gherkin/dialect.rb', line 46

def when_keywords
  @spec.fetch('when')
end