Debian Codegraph @

gherkin/i18n.go

raw
1 package gherkin
2
3 type Language string
4
5 // Translation represents the Gherkin syntax keywords in a single language.
6 type Translation struct {
7 // Language specific term representing a feature.
8 Feature string
9
10 // Language specific term representing the feature background.
11 Background string
12
13 // Language specific term representing a scenario.
14 Scenario string
15
16 // Language specific term representing a scenario outline.
17 Outline string
18
19 // Language specific term representing the "And" step.
20 And string
21
22 // Language specific term representing the "Given" step.
23 Given string
24
25 // Language specific term representing the "When" step.
26 When string
27
28 // Language specific term representing the "Then" step.
29 Then string
30
31 // Language specific term representing a scenario outline prefix.
32 Examples string
33 }
34
35 const (
36 // The language code for English translations.
37 LANG_EN = Language("en")
38 )
39
40 var (
41 // Translations contains internationalized translations of the Gherkin
42 // syntax keywords in a variety of supported languages.
43 Translations = map[Language]Translation{
44 LANG_EN: Translation{
45 Feature: "Feature",
46 Background: "Background",
47 Scenario: "Scenario",
48 Outline: "Scenario Outline",
49 And: "And",
50 Given: "Given",
51 When: "When",
52 Then: "Then",
53 Examples: "Examples",
54 },
55 }
56 )