Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions tests/Cucumber/CompatibilityTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,13 @@ class CompatibilityTest extends TestCase
'incomplete_background_2.feature' => 'Background descriptions not supported',
'examples_keyword_in_background_description.feature' => 'Background descriptions not supported',
'extra_blank_lines_everywhere.feature' => 'Background / Examples descriptions not supported',
'addition.feature' => 'Trailing whitespace in description lines is trimmed',
'hashes_in_quotes.feature' => 'Trailing whitespace in description lines is trimmed',
'multiline_name.feature' => 'Multiline titles are folded into the title instead of the description',
'multiline_name_with_newlines.feature' => 'Multiline titles are folded into the title instead of the description',
'issue_13.feature' => 'Multiline titles are folded into the title instead of the description',
'background_title.feature' => 'Multiline titles are folded into the title instead of the description',
'complex_descriptions.feature' => 'Multiline titles are folded into the title instead of the description',
],
'gherkin-32' => [
'complex_background.feature' => 'Rule keyword not supported',
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
Behat\Gherkin\Node\FeatureNode:
title: Addition
description: |-
In order to avoid silly mistakes
As a math idiot
I want to be told the sum of two numbers
tags: []
background: ~
scenarios:
-
Behat\Gherkin\Node\ScenarioNode:
title: 'Add two numbers'
tags: []
steps:
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'Given I have entered 11 into the calculator'
keyword: Given
text: 'I have entered 11 into the calculator'
arguments: []
line: 8
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'And I have entered 12 into the calculator'
keyword: And
text: 'I have entered 12 into the calculator'
arguments: []
line: 9
-
Behat\Gherkin\Node\StepNode:
keywordType: When
fullText: 'When I press add'
keyword: When
text: 'I press add'
arguments: []
line: 10
-
Behat\Gherkin\Node\StepNode:
keywordType: Then
fullText: 'Then the result should be 23 on the screen'
keyword: Then
text: 'the result should be 23 on the screen'
arguments: []
line: 11
keyword: Scenario
line: 7
description: ~
-
Behat\Gherkin\Node\ScenarioNode:
title: 'Div two numbers'
tags: []
steps:
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'Given I have entered 10 into the calculator'
keyword: Given
text: 'I have entered 10 into the calculator'
arguments: []
line: 14
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'And I have entered 2 into the calculator'
keyword: And
text: 'I have entered 2 into the calculator'
arguments: []
line: 15
-
Behat\Gherkin\Node\StepNode:
keywordType: When
fullText: 'When I press div'
keyword: When
text: 'I press div'
arguments: []
line: 16
-
Behat\Gherkin\Node\StepNode:
keywordType: Then
fullText: 'Then the result should be 5 on the screen'
keyword: Then
text: 'the result should be 5 on the screen'
arguments: []
line: 17
keyword: Scenario
line: 13
description: ~
keyword: Feature
language: en
file: {BASEDIR}/tests/Cucumber/extra_testdata/good/addition.feature
line: 2
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
Behat\Gherkin\Node\FeatureNode:
title: 'Feature with titled background'
description: ~
tags: []
background:
Behat\Gherkin\Node\BackgroundNode:
title: |-
Some Background
title with
couple
of
| continuous |
"""
strings
steps:
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'Given a passing step'
keyword: Given
text: 'a passing step'
arguments: []
line: 10
keyword: Background
line: 3
description: ~
scenarios:
-
Behat\Gherkin\Node\ScenarioNode:
title: ~
tags: []
steps:
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'Given a failing step'
keyword: Given
text: 'a failing step'
arguments: []
line: 13
keyword: Scenario
line: 12
description: ~
keyword: Feature
language: en
file: {BASEDIR}/tests/Cucumber/extra_testdata/good/background_title.feature
line: 1
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
Behat\Gherkin\Node\FeatureNode:
title: 'Complex descriptions'
description: |-
Some description with
| table | row|

and

"""
"""
tags: []
background: ~
scenarios:
-
Behat\Gherkin\Node\ScenarioNode:
title: |-
Some
| complex | description |

"""
hell yeah
"""
tags: []
steps:
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'Given one two three'
keyword: Given
text: 'one two three'
arguments: []
line: 22
keyword: Scenario
line: 16
description: ~
keyword: Feature
language: en
file: {BASEDIR}/tests/Cucumber/extra_testdata/good/complex_descriptions.feature
line: 7
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
Behat\Gherkin\Node\FeatureNode:
title: "Some '#quoted' string"
description: |-
In order to avoid silly mistakes
As a "#math" idiot
I want to be told the sum of two numbers
tags: []
background: ~
scenarios:
-
Behat\Gherkin\Node\ScenarioNode:
title: 'Add two numbers'
tags: []
steps:
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'Given I have entered 11 into the calculator'
keyword: Given
text: 'I have entered 11 into the calculator'
arguments: []
line: 8
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'And I have entered 12 into the calculator'
keyword: And
text: 'I have entered 12 into the calculator'
arguments: []
line: 9
-
Behat\Gherkin\Node\StepNode:
keywordType: When
fullText: 'When I press "#add"'
keyword: When
text: 'I press "#add"'
arguments: []
line: 10
-
Behat\Gherkin\Node\StepNode:
keywordType: Then
fullText: 'Then the result should be 23 on the screen'
keyword: Then
text: 'the result should be 23 on the screen'
arguments: []
line: 11
keyword: Scenario
line: 7
description: ~
-
Behat\Gherkin\Node\ScenarioNode:
title: 'Div "#two" numbers # as'
tags: []
steps:
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'Given I have entered 10 into the calculator'
keyword: Given
text: 'I have entered 10 into the calculator'
arguments: []
line: 14
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'And I have entered # 2 into the calculator'
keyword: And
text: 'I have entered # 2 into the calculator'
arguments: []
line: 15
-
Behat\Gherkin\Node\StepNode:
keywordType: When
fullText: 'When I press div'
keyword: When
text: 'I press div'
arguments: []
line: 16
-
Behat\Gherkin\Node\StepNode:
keywordType: Then
fullText: 'Then the result should be 5 on the screen'
keyword: Then
text: 'the result should be 5 on the screen'
arguments: []
line: 17
keyword: Scenario
line: 13
description: ~
keyword: Feature
language: en
file: {BASEDIR}/tests/Cucumber/extra_testdata/good/hashes_in_quotes.feature
line: 2
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
Behat\Gherkin\Node\FeatureNode:
title: 'test pystring'
description: 'second line'
tags: []
background: ~
scenarios:
-
Behat\Gherkin\Node\ScenarioNode:
title: |-
testing py string in scenario
second line
tags: []
steps:
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'Given the pystring is'
keyword: Given
text: 'the pystring is'
arguments:
-
Behat\Gherkin\Node\PyStringNode:
strings:
- 'Test store name'
- 'Denmark, Kolding'
- '6000'
line: 8
line: 7
keyword: Scenario
line: 4
description: ~
-
Behat\Gherkin\Node\OutlineNode:
tables:
-
Behat\Gherkin\Node\ExampleTableNode:
keyword: Examples
tags: []
name: ~
description: ~
maxLineLength:
- 0
table:
24:
- ''
examples: '**NOT INITIALIZED**'
title: |-
testing py string in scenario outline
second line
tags: []
steps:
-
Behat\Gherkin\Node\StepNode:
keywordType: Given
fullText: 'Given the pystring is'
keyword: Given
text: 'the pystring is'
arguments:
-
Behat\Gherkin\Node\PyStringNode:
strings:
- 'Test store name'
- 'Denmark, Kolding'
- '6000'
line: 18
line: 17
keyword: 'Scenario Outline'
line: 14
description: ~
keyword: Feature
language: en
file: {BASEDIR}/tests/Cucumber/extra_testdata/good/issue_13.feature
line: 1
Loading