bryanl-gherkin 2.11.1.1-java
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitattributes +2 -0
- data/.mailmap +2 -0
- data/.rbenv-gemsets +1 -0
- data/.rspec +1 -0
- data/.rvmrc +1 -0
- data/.travis.yml +16 -0
- data/.yardopts +5 -0
- data/Gemfile +5 -0
- data/History.md +788 -0
- data/LICENSE +20 -0
- data/README.md +272 -0
- data/Rakefile +26 -0
- data/build_native_gems.sh +7 -0
- data/cucumber.yml +4 -0
- data/examples/parse_and_output_json.rb +19 -0
- data/features/.cucumber/stepdefs.json +244 -0
- data/features/escaped_pipes.feature +8 -0
- data/features/feature_parser.feature +237 -0
- data/features/json_formatter.feature +498 -0
- data/features/json_parser.feature +331 -0
- data/features/native_lexer.feature +19 -0
- data/features/parser_with_native_lexer.feature +205 -0
- data/features/pretty_formatter.feature +16 -0
- data/features/step_definitions/eyeball_steps.rb +3 -0
- data/features/step_definitions/gherkin_steps.rb +29 -0
- data/features/step_definitions/json_formatter_steps.rb +30 -0
- data/features/step_definitions/json_parser_steps.rb +20 -0
- data/features/step_definitions/pretty_formatter_steps.rb +85 -0
- data/features/steps_parser.feature +46 -0
- data/features/support/env.rb +42 -0
- data/gherkin.gemspec +77 -0
- data/install_mingw_os_x.sh +7 -0
- data/js/.npmignore +1 -0
- data/js/lib/gherkin/lexer/.npmignore +0 -0
- data/lib/gherkin/c_lexer.rb +17 -0
- data/lib/gherkin/formatter/ansi_escapes.rb +97 -0
- data/lib/gherkin/formatter/argument.rb +16 -0
- data/lib/gherkin/formatter/escaping.rb +15 -0
- data/lib/gherkin/formatter/filter_formatter.rb +146 -0
- data/lib/gherkin/formatter/hashable.rb +19 -0
- data/lib/gherkin/formatter/json_formatter.rb +122 -0
- data/lib/gherkin/formatter/line_filter.rb +26 -0
- data/lib/gherkin/formatter/model.rb +281 -0
- data/lib/gherkin/formatter/pretty_formatter.rb +244 -0
- data/lib/gherkin/formatter/regexp_filter.rb +21 -0
- data/lib/gherkin/formatter/step_printer.rb +21 -0
- data/lib/gherkin/formatter/tag_count_formatter.rb +47 -0
- data/lib/gherkin/formatter/tag_filter.rb +19 -0
- data/lib/gherkin/i18n.rb +180 -0
- data/lib/gherkin/i18n.yml +613 -0
- data/lib/gherkin/js_lexer.rb +20 -0
- data/lib/gherkin/json_parser.rb +177 -0
- data/lib/gherkin/lexer/i18n_lexer.rb +46 -0
- data/lib/gherkin/listener/event.rb +45 -0
- data/lib/gherkin/listener/formatter_listener.rb +143 -0
- data/lib/gherkin/native/java.rb +72 -0
- data/lib/gherkin/native/null.rb +5 -0
- data/lib/gherkin/native/therubyracer.rb +39 -0
- data/lib/gherkin/native.rb +7 -0
- data/lib/gherkin/parser/meta.txt +5 -0
- data/lib/gherkin/parser/parser.rb +164 -0
- data/lib/gherkin/parser/root.txt +11 -0
- data/lib/gherkin/parser/steps.txt +4 -0
- data/lib/gherkin/rb_lexer/README.rdoc +8 -0
- data/lib/gherkin/rb_lexer.rb +8 -0
- data/lib/gherkin/rubify.rb +24 -0
- data/lib/gherkin/tag_expression.rb +62 -0
- data/lib/gherkin.jar +0 -0
- data/lib/gherkin.rb +2 -0
- data/ragel/lexer.c.rl.erb +454 -0
- data/ragel/lexer.java.rl.erb +219 -0
- data/ragel/lexer.js.rl.erb +227 -0
- data/ragel/lexer.rb.rl.erb +174 -0
- data/ragel/lexer_common.rl.erb +50 -0
- data/spec/gherkin/c_lexer_spec.rb +22 -0
- data/spec/gherkin/fixtures/1.feature +8 -0
- data/spec/gherkin/fixtures/comments_in_table.feature +9 -0
- data/spec/gherkin/fixtures/complex.feature +45 -0
- data/spec/gherkin/fixtures/complex.json +139 -0
- data/spec/gherkin/fixtures/complex_for_filtering.feature +60 -0
- data/spec/gherkin/fixtures/complex_with_tags.feature +61 -0
- data/spec/gherkin/fixtures/dos_line_endings.feature +45 -0
- data/spec/gherkin/fixtures/examples_with_only_header.feature +14 -0
- data/spec/gherkin/fixtures/hantu_pisang.feature +35 -0
- data/spec/gherkin/fixtures/i18n_fr.feature +14 -0
- data/spec/gherkin/fixtures/i18n_fr2.feature +8 -0
- data/spec/gherkin/fixtures/i18n_no.feature +7 -0
- data/spec/gherkin/fixtures/i18n_pt1.feature +44 -0
- data/spec/gherkin/fixtures/i18n_pt2.feature +4 -0
- data/spec/gherkin/fixtures/i18n_pt3.feature +4 -0
- data/spec/gherkin/fixtures/i18n_pt4.feature +4 -0
- data/spec/gherkin/fixtures/i18n_zh-CN.feature +9 -0
- data/spec/gherkin/fixtures/issue_145.feature +22 -0
- data/spec/gherkin/fixtures/scenario_outline_with_tags.feature +13 -0
- data/spec/gherkin/fixtures/scenario_without_steps.feature +5 -0
- data/spec/gherkin/fixtures/simple_with_comments.feature +7 -0
- data/spec/gherkin/fixtures/simple_with_tags.feature +11 -0
- data/spec/gherkin/fixtures/with_bom.feature +3 -0
- data/spec/gherkin/formatter/ansi_escapes_spec.rb +32 -0
- data/spec/gherkin/formatter/filter_formatter_spec.rb +204 -0
- data/spec/gherkin/formatter/json_formatter_spec.rb +92 -0
- data/spec/gherkin/formatter/model_spec.rb +28 -0
- data/spec/gherkin/formatter/pretty_formatter_spec.rb +177 -0
- data/spec/gherkin/formatter/spaces.feature +9 -0
- data/spec/gherkin/formatter/step_printer_spec.rb +55 -0
- data/spec/gherkin/formatter/tabs.feature +9 -0
- data/spec/gherkin/formatter/tag_count_formatter_spec.rb +30 -0
- data/spec/gherkin/i18n_spec.rb +241 -0
- data/spec/gherkin/java_lexer_spec.rb +20 -0
- data/spec/gherkin/js_lexer_spec.rb +23 -0
- data/spec/gherkin/json_parser_spec.rb +176 -0
- data/spec/gherkin/lexer/i18n_lexer_spec.rb +43 -0
- data/spec/gherkin/output_stream_string_io.rb +20 -0
- data/spec/gherkin/parser/parser_spec.rb +16 -0
- data/spec/gherkin/rb_lexer_spec.rb +20 -0
- data/spec/gherkin/sexp_recorder.rb +59 -0
- data/spec/gherkin/shared/bom_group.rb +20 -0
- data/spec/gherkin/shared/doc_string_group.rb +163 -0
- data/spec/gherkin/shared/lexer_group.rb +591 -0
- data/spec/gherkin/shared/row_group.rb +125 -0
- data/spec/gherkin/shared/tags_group.rb +54 -0
- data/spec/gherkin/tag_expression_spec.rb +142 -0
- data/spec/spec_helper.rb +75 -0
- data/tasks/bench/feature_builder.rb +49 -0
- data/tasks/bench/null_listener.rb +4 -0
- data/tasks/bench.rake +184 -0
- data/tasks/compile.rake +120 -0
- data/tasks/cucumber.rake +22 -0
- data/tasks/gems.rake +31 -0
- data/tasks/ikvm.rake +124 -0
- data/tasks/ragel_task.rb +100 -0
- data/tasks/release.rake +49 -0
- data/tasks/rspec.rake +8 -0
- data/tasks/yard/default/layout/html/bubble_32x32.png +0 -0
- data/tasks/yard/default/layout/html/bubble_48x48.png +0 -0
- data/tasks/yard/default/layout/html/footer.erb +5 -0
- data/tasks/yard/default/layout/html/index.erb +1 -0
- data/tasks/yard/default/layout/html/layout.erb +25 -0
- data/tasks/yard/default/layout/html/logo.erb +1 -0
- data/tasks/yard/default/layout/html/setup.rb +4 -0
- data/tasks/yard.rake +7 -0
- metadata +412 -0
@@ -0,0 +1,45 @@
|
|
1
|
+
#Comment on line 1
|
2
|
+
#Comment on line 2
|
3
|
+
@tag1 @tag2
|
4
|
+
Feature: Feature Text
|
5
|
+
In order to test multiline forms
|
6
|
+
As a ragel writer
|
7
|
+
I need to check for complex combinations
|
8
|
+
|
9
|
+
#Comment on line 9
|
10
|
+
|
11
|
+
#Comment on line 11
|
12
|
+
|
13
|
+
Background:
|
14
|
+
Given this is a background step
|
15
|
+
And this is another one
|
16
|
+
|
17
|
+
@tag3 @tag4
|
18
|
+
Scenario: Reading a Scenario
|
19
|
+
Given there is a step
|
20
|
+
But not another step
|
21
|
+
|
22
|
+
@tag3
|
23
|
+
Scenario: Reading a second scenario
|
24
|
+
With two lines of text
|
25
|
+
#Comment on line 24
|
26
|
+
Given a third step with a table
|
27
|
+
|a|b|
|
28
|
+
|c|d|
|
29
|
+
|e|f|
|
30
|
+
And I am still testing things
|
31
|
+
|g|h|
|
32
|
+
|e|r|
|
33
|
+
|k|i|
|
34
|
+
|n||
|
35
|
+
And I am done testing these tables
|
36
|
+
#Comment on line 29
|
37
|
+
Then I am happy
|
38
|
+
|
39
|
+
Scenario: Hammerzeit
|
40
|
+
Given All work and no play
|
41
|
+
"""
|
42
|
+
Makes Homer something something
|
43
|
+
And something else
|
44
|
+
"""
|
45
|
+
Then crazy
|
@@ -0,0 +1,139 @@
|
|
1
|
+
{
|
2
|
+
"id": "feature-text",
|
3
|
+
"uri": "some/nice.feature",
|
4
|
+
"name": "Feature Text",
|
5
|
+
"keyword": "Feature",
|
6
|
+
"description": "In order to test multiline forms",
|
7
|
+
"tags": [
|
8
|
+
{"name": "@tag1"},
|
9
|
+
{"name": "@tag2"}
|
10
|
+
],
|
11
|
+
"elements": [
|
12
|
+
{ "type": "background",
|
13
|
+
"description": "",
|
14
|
+
"name": "",
|
15
|
+
"keyword": "Background",
|
16
|
+
"steps": [
|
17
|
+
{ "name": "this is a background step",
|
18
|
+
"keyword": "Given " },
|
19
|
+
{ "name": "this is another one",
|
20
|
+
"keyword": "When ",
|
21
|
+
"line": 412 }
|
22
|
+
]
|
23
|
+
},
|
24
|
+
{ "type": "scenario_outline",
|
25
|
+
"id": "feature-text/a-scenario-outline",
|
26
|
+
"keyword": "Scenario Outline",
|
27
|
+
"name": "An Scenario Outline",
|
28
|
+
"description": "",
|
29
|
+
"tags": [
|
30
|
+
{"name": "@foo"}
|
31
|
+
],
|
32
|
+
"steps": [
|
33
|
+
{ "name": "A step with a table",
|
34
|
+
"keyword": "Given ",
|
35
|
+
"rows" : [
|
36
|
+
{"cells": [ "a","row","for","a","step" ]}
|
37
|
+
]
|
38
|
+
}
|
39
|
+
],
|
40
|
+
"examples": [
|
41
|
+
{
|
42
|
+
"id": "feature-text/a-scenario-outline/sweet-example",
|
43
|
+
"name": "Sweet Example",
|
44
|
+
"keyword": "Examples",
|
45
|
+
"description": "",
|
46
|
+
"rows" : [
|
47
|
+
{"cells" :
|
48
|
+
[ "Fill","In" ]
|
49
|
+
},
|
50
|
+
{"cells" :
|
51
|
+
[ "The","Blanks" ]
|
52
|
+
}
|
53
|
+
],
|
54
|
+
"tags" : [ {"name": "@exampletag"} ]
|
55
|
+
}
|
56
|
+
]
|
57
|
+
},
|
58
|
+
{ "type" : "scenario",
|
59
|
+
"id": "feature-text/reading-a-scenario",
|
60
|
+
"keyword": "Scenario",
|
61
|
+
"name" : "Reading a Scenario",
|
62
|
+
"description": "",
|
63
|
+
"tags" : [
|
64
|
+
{"name": "@tag3"},
|
65
|
+
{"name": "@tag4"}
|
66
|
+
],
|
67
|
+
"steps" : [
|
68
|
+
{ "name" : "there is a step",
|
69
|
+
"keyword": "Given "},
|
70
|
+
{ "name" : "not another step",
|
71
|
+
"keyword": "But " }
|
72
|
+
]
|
73
|
+
},
|
74
|
+
{ "type" : "scenario",
|
75
|
+
"id": "feature-text/reading-a-second-scenario",
|
76
|
+
"keyword": "Scenario",
|
77
|
+
"name" : "Reading a second scenario",
|
78
|
+
"description": "With two lines of text",
|
79
|
+
"tags" : [ {"name": "@tag3"} ],
|
80
|
+
"steps" : [
|
81
|
+
{ "name" : "a third step with a table",
|
82
|
+
"keyword": "Given ",
|
83
|
+
"rows": [
|
84
|
+
{
|
85
|
+
"cells" : [ "a","b" ],
|
86
|
+
"line" : 987
|
87
|
+
},
|
88
|
+
{ "cells" :
|
89
|
+
[ "c","d" ]
|
90
|
+
},
|
91
|
+
{ "cells" :
|
92
|
+
[ "e", "f" ]
|
93
|
+
}
|
94
|
+
]
|
95
|
+
},
|
96
|
+
{ "name" : "I am still testing things",
|
97
|
+
"keyword": "Given ",
|
98
|
+
"rows": [
|
99
|
+
{ "cells" :
|
100
|
+
[ "g","h" ]
|
101
|
+
},
|
102
|
+
{ "cells" :
|
103
|
+
[ "e","r" ]
|
104
|
+
},
|
105
|
+
{ "cells" :
|
106
|
+
[ "k", "i" ]
|
107
|
+
},
|
108
|
+
{ "cells" :
|
109
|
+
[ "n", "" ]
|
110
|
+
}
|
111
|
+
]
|
112
|
+
},
|
113
|
+
{ "name" : "I am done testing these tables",
|
114
|
+
"keyword": "Given " },
|
115
|
+
{ "name" : "I am happy",
|
116
|
+
"keyword": "Given " }
|
117
|
+
]
|
118
|
+
},
|
119
|
+
{ "type" : "scenario",
|
120
|
+
"id": "feature-text/hammerzeit",
|
121
|
+
"keyword": "Scenario",
|
122
|
+
"name" : "Hammerzeit",
|
123
|
+
"description": "",
|
124
|
+
"steps" : [
|
125
|
+
{ "name" : "All work and no play",
|
126
|
+
"keyword": "Given ",
|
127
|
+
"doc_string": {
|
128
|
+
"content_type": "text",
|
129
|
+
"value": "Makes Homer something something\nAnd something else",
|
130
|
+
"line": 777
|
131
|
+
}
|
132
|
+
},
|
133
|
+
{ "name" : "crazy",
|
134
|
+
"keyword": "Given " }
|
135
|
+
]
|
136
|
+
}
|
137
|
+
]
|
138
|
+
}
|
139
|
+
|
@@ -0,0 +1,60 @@
|
|
1
|
+
#Comment on line 1
|
2
|
+
#Comment on line 2
|
3
|
+
@tag1 @tag2
|
4
|
+
Feature: Feature Text
|
5
|
+
In order to test multiline forms
|
6
|
+
As a ragel writer
|
7
|
+
I need to check for complex combinations
|
8
|
+
|
9
|
+
#Comment on line 9
|
10
|
+
#Comment on line 11
|
11
|
+
Background:
|
12
|
+
Given this is a background step
|
13
|
+
And this is another one
|
14
|
+
|
15
|
+
@tag3 @tag4
|
16
|
+
Scenario: Reading a Scenario
|
17
|
+
Given there is a step
|
18
|
+
But not another step
|
19
|
+
|
20
|
+
@tag3
|
21
|
+
Scenario: Reading a second scenario
|
22
|
+
With two lines of text
|
23
|
+
|
24
|
+
#Comment on line 24
|
25
|
+
Given a third step with a table
|
26
|
+
| a | b |
|
27
|
+
| c | d |
|
28
|
+
| e | f |
|
29
|
+
And I am still testing things
|
30
|
+
And I am done testing these tables
|
31
|
+
#Comment on line 29
|
32
|
+
Then I am happy
|
33
|
+
| g | h |
|
34
|
+
| e | r |
|
35
|
+
| k | i |
|
36
|
+
| n | |
|
37
|
+
|
38
|
+
Scenario: Hammerzeit XX
|
39
|
+
Given All work and no play
|
40
|
+
Then crazy
|
41
|
+
"""
|
42
|
+
Makes Homer something something
|
43
|
+
And something else
|
44
|
+
"""
|
45
|
+
|
46
|
+
@more
|
47
|
+
Scenario Outline: More
|
48
|
+
Given Some <whaaa>
|
49
|
+
|
50
|
+
@neat
|
51
|
+
Examples: Neato XX
|
52
|
+
| whaa |
|
53
|
+
| neat |
|
54
|
+
| beat |
|
55
|
+
|
56
|
+
@hamster
|
57
|
+
Examples: Rodents
|
58
|
+
| whaa |
|
59
|
+
| hammy |
|
60
|
+
| mousy |
|
@@ -0,0 +1,61 @@
|
|
1
|
+
#Comment on line 1
|
2
|
+
#Comment on line 2
|
3
|
+
@tag1 @tag2
|
4
|
+
Feature: Feature Text
|
5
|
+
In order to test multiline forms
|
6
|
+
As a ragel writer
|
7
|
+
I need to check for complex combinations
|
8
|
+
|
9
|
+
#Comment on line 9
|
10
|
+
|
11
|
+
#Comment on line 11
|
12
|
+
|
13
|
+
Background:
|
14
|
+
Given this is a background step
|
15
|
+
And this is another one
|
16
|
+
|
17
|
+
@tag3 @tag4
|
18
|
+
Scenario: Reading a Scenario
|
19
|
+
Given there is a step
|
20
|
+
But not another step
|
21
|
+
|
22
|
+
@tag3
|
23
|
+
Scenario: Reading a second scenario
|
24
|
+
With two lines of text
|
25
|
+
#Comment on line 24
|
26
|
+
Given a third step with a table
|
27
|
+
|a|b|
|
28
|
+
|c|d|
|
29
|
+
|e|f|
|
30
|
+
And I am still testing things
|
31
|
+
|g|h|
|
32
|
+
|e|r|
|
33
|
+
|k|i|
|
34
|
+
|n||
|
35
|
+
And I am done testing these tables
|
36
|
+
#Comment on line 29
|
37
|
+
Then I am happy
|
38
|
+
|
39
|
+
Scenario: Hammerzeit
|
40
|
+
Given All work and no play
|
41
|
+
"""
|
42
|
+
Makes Homer something something
|
43
|
+
And something else
|
44
|
+
"""
|
45
|
+
Then crazy
|
46
|
+
|
47
|
+
@more
|
48
|
+
Scenario Outline: More
|
49
|
+
Given Some <whaaa>
|
50
|
+
|
51
|
+
@neat
|
52
|
+
Examples: Neato
|
53
|
+
|whaa|
|
54
|
+
|neat|
|
55
|
+
|beat|
|
56
|
+
|
57
|
+
@hamster
|
58
|
+
Examples: Rodents
|
59
|
+
|whaa|
|
60
|
+
|hammy|
|
61
|
+
|mousy|
|
@@ -0,0 +1,45 @@
|
|
1
|
+
#Comment on line 1
|
2
|
+
#Comment on line 2
|
3
|
+
@tag1 @tag2
|
4
|
+
Feature: Feature Text
|
5
|
+
In order to test multiline forms
|
6
|
+
As a ragel writer
|
7
|
+
I need to check for complex combinations
|
8
|
+
|
9
|
+
#Comment on line 9
|
10
|
+
|
11
|
+
#Comment on line 11
|
12
|
+
|
13
|
+
Background:
|
14
|
+
Given this is a background step
|
15
|
+
And this is another one
|
16
|
+
|
17
|
+
@tag3 @tag4
|
18
|
+
Scenario: Reading a Scenario
|
19
|
+
Given there is a step
|
20
|
+
But not another step
|
21
|
+
|
22
|
+
@tag3
|
23
|
+
Scenario: Reading a second scenario
|
24
|
+
With two lines of text
|
25
|
+
#Comment on line 24
|
26
|
+
Given a third step with a table
|
27
|
+
|a|b|
|
28
|
+
|c|d|
|
29
|
+
|e|f|
|
30
|
+
And I am still testing things
|
31
|
+
|g|h|
|
32
|
+
|e|r|
|
33
|
+
|k|i|
|
34
|
+
|n||
|
35
|
+
And I am done testing these tables
|
36
|
+
#Comment on line 29
|
37
|
+
Then I am happy
|
38
|
+
|
39
|
+
Scenario: Hammerzeit
|
40
|
+
Given All work and no play
|
41
|
+
"""
|
42
|
+
Makes Homer something something
|
43
|
+
And something else
|
44
|
+
"""
|
45
|
+
Then crazy
|
@@ -0,0 +1,14 @@
|
|
1
|
+
Feature: An example with only a header
|
2
|
+
See [this thread](http://groups.google.com/group/cukes/browse_thread/thread/3e55777ee29c445c)
|
3
|
+
|
4
|
+
Scenario Outline:
|
5
|
+
When I do <foo>
|
6
|
+
Then something
|
7
|
+
|
8
|
+
Examples: A
|
9
|
+
| page |
|
10
|
+
| Golf |
|
11
|
+
|
12
|
+
@failing
|
13
|
+
Examples: B
|
14
|
+
| Scottish Football |
|
@@ -0,0 +1,35 @@
|
|
1
|
+
Feature: search examples
|
2
|
+
|
3
|
+
Background: The background
|
4
|
+
Given passing without a table
|
5
|
+
|
6
|
+
Scenario: should match Hantu Pisang
|
7
|
+
Given passing without a table
|
8
|
+
|
9
|
+
Scenario: Ignore me
|
10
|
+
Given failing without a table
|
11
|
+
|
12
|
+
Scenario Outline: Ignore me
|
13
|
+
Given <state> without a table
|
14
|
+
|
15
|
+
Examples:
|
16
|
+
| state |
|
17
|
+
| 1111111 |
|
18
|
+
|
19
|
+
Scenario Outline: Hantu Pisang match
|
20
|
+
Given <state> without a table
|
21
|
+
|
22
|
+
Examples:
|
23
|
+
| state |
|
24
|
+
| 2222222 |
|
25
|
+
|
26
|
+
Scenario Outline: no match in name but in examples
|
27
|
+
Given <state> without a table
|
28
|
+
|
29
|
+
Examples: Hantu Pisang
|
30
|
+
| state |
|
31
|
+
| 3333333 |
|
32
|
+
|
33
|
+
Examples: Ignore me
|
34
|
+
| state |
|
35
|
+
| 4444444 |
|
@@ -0,0 +1,14 @@
|
|
1
|
+
#language:fr
|
2
|
+
Fonctionnalité: Addition
|
3
|
+
Plan du scénario: Addition de produits dérivés
|
4
|
+
Soit une calculatrice
|
5
|
+
Etant donné qu'on tape <a>
|
6
|
+
Et qu'on tape <b>
|
7
|
+
Lorsqu'on tape additionner
|
8
|
+
Alors le résultat doit être <somme>
|
9
|
+
|
10
|
+
Exemples:
|
11
|
+
| a | b | somme |
|
12
|
+
| 2 | 2 | 4 |
|
13
|
+
| 2 | 3 | 5 |
|
14
|
+
|
@@ -0,0 +1,44 @@
|
|
1
|
+
# language: pt
|
2
|
+
Funcionalidade: Reconhece "Funcionalidade"
|
3
|
+
|
4
|
+
Contexto: Reconhece "Contexto"
|
5
|
+
|
6
|
+
Cenário: Reconhece "Cenário" com acento
|
7
|
+
|
8
|
+
Cenario: Reconhece "Cenário" sem acento
|
9
|
+
|
10
|
+
Esquema do Cenário: Reconhece "Esquema do Cenário" com acento
|
11
|
+
Dado que <Valor> é um valor e que reconhece "Dado";
|
12
|
+
Dada a afirmação de que reconhece "Dada";
|
13
|
+
Dados os factos acima e ainda que reconhece "Dados";
|
14
|
+
Dadas as afirmações acima e ainda que reconhece "Dadas";
|
15
|
+
Quando reconhece "Quando";
|
16
|
+
Então também reconhece "Então" com acento e
|
17
|
+
Entao também reconhece "Então" sem acento;
|
18
|
+
E reconhece "E";
|
19
|
+
Mas também reconhece "Mas".
|
20
|
+
|
21
|
+
Exemplos: Reconhece "Exemplos"
|
22
|
+
| Valor |
|
23
|
+
| 1 |
|
24
|
+
|
25
|
+
Esquema do Cenario: Reconhece "Esquema do Cenário" sem acento
|
26
|
+
Dado que <Valor> é um valor;
|
27
|
+
|
28
|
+
Cenários: Reconhece "Cenários" com acento
|
29
|
+
| Valor |
|
30
|
+
| 1 |
|
31
|
+
|
32
|
+
Delineação do Cenário: Reconhece "Delineação do Cenário" com acento
|
33
|
+
Dado que <Valor> é um valor;
|
34
|
+
|
35
|
+
Cenarios: Reconhece "Cenários" sem acento
|
36
|
+
| Valor |
|
37
|
+
| 1 |
|
38
|
+
|
39
|
+
Delineacao do Cenario: Reconhece "Delineação do Cenário" sem acento
|
40
|
+
Dado que <Valor> é um valor;
|
41
|
+
|
42
|
+
Exemplos: Reconhece "Exemplos"
|
43
|
+
| Valor |
|
44
|
+
| 1 |
|
@@ -0,0 +1,22 @@
|
|
1
|
+
Feature: issue 145
|
2
|
+
|
3
|
+
Scenario: Scenario 1
|
4
|
+
Given some condition
|
5
|
+
|
6
|
+
Scenario Outline: Scenario 2
|
7
|
+
Given some condition
|
8
|
+
When I go to <page>
|
9
|
+
Then some assertion
|
10
|
+
|
11
|
+
Examples:
|
12
|
+
| page |
|
13
|
+
| /aaaa |
|
14
|
+
| /bbbb |
|
15
|
+
| /cccc |
|
16
|
+
|
17
|
+
Scenario: Scenario 3
|
18
|
+
Given some condition
|
19
|
+
|
20
|
+
Scenario: Scenario 4
|
21
|
+
Given some condition
|
22
|
+
|
@@ -0,0 +1,32 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
require 'gherkin/formatter/ansi_escapes'
|
3
|
+
|
4
|
+
module Gherkin
|
5
|
+
module Formatter
|
6
|
+
describe AnsiEscapes do
|
7
|
+
describe "instance methods" do
|
8
|
+
include AnsiEscapes
|
9
|
+
|
10
|
+
it "failed should be red" do
|
11
|
+
failed.should == "\e[31m"
|
12
|
+
end
|
13
|
+
|
14
|
+
it "failed_arg should be red bold" do
|
15
|
+
failed_arg.should == "\e[31m\e[1m"
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
describe "class methods" do
|
20
|
+
subject { AnsiEscapes }
|
21
|
+
|
22
|
+
it "failed should be red" do
|
23
|
+
subject.failed.should == "\e[31m"
|
24
|
+
end
|
25
|
+
|
26
|
+
it "failed_arg should be red bold" do
|
27
|
+
subject.failed_arg.should == "\e[31m\e[1m"
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|