Skip to content

Commit fa996ea

Browse files
committed
Test [filepart]
I suspected this failed on Windows, but it turns out that it works.
1 parent 790fc96 commit fa996ea

File tree

1 file changed

+59
-0
lines changed

1 file changed

+59
-0
lines changed

features/step_definitions.feature

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,3 +46,62 @@ Feature: step definitions
4646
"""
4747
When I run cypress
4848
Then it passes
49+
50+
Rule: [filePart] should allow for step definitions on multiple levels
51+
52+
Background:
53+
Given additional preprocessor configuration
54+
"""
55+
{
56+
"stepDefinitions": "cypress/e2e/[filepart]/steps.js"
57+
}
58+
"""
59+
And a file named "cypress/e2e/foo/bar/baz/a.feature" with:
60+
"""
61+
@a
62+
Feature: a feature name
63+
Scenario: a scenario name
64+
Given a step
65+
"""
66+
And a file named "cypress/e2e/b.feature" with:
67+
"""
68+
Feature: another feature name
69+
Scenario: another scenario name
70+
Given another step
71+
"""
72+
73+
Scenario: first level
74+
Given a file named "cypress/e2e/steps.js" with:
75+
"""
76+
const { Given } = require("@badeball/cypress-cucumber-preprocessor");
77+
Given("a step", function() {});
78+
"""
79+
When I run cypress with "-e tags=@a"
80+
Then it passes
81+
82+
Scenario: second level
83+
Given a file named "cypress/e2e/foo/steps.js" with:
84+
"""
85+
const { Given } = require("@badeball/cypress-cucumber-preprocessor");
86+
Given("a step", function() {});
87+
"""
88+
When I run cypress with "-e tags=@a"
89+
Then it passes
90+
91+
Scenario: third level
92+
Given a file named "cypress/e2e/foo/bar/steps.js" with:
93+
"""
94+
const { Given } = require("@badeball/cypress-cucumber-preprocessor");
95+
Given("a step", function() {});
96+
"""
97+
When I run cypress with "-e tags=@a"
98+
Then it passes
99+
100+
Scenario: fourth level
101+
Given a file named "cypress/e2e/foo/bar/baz/steps.js" with:
102+
"""
103+
const { Given } = require("@badeball/cypress-cucumber-preprocessor");
104+
Given("a step", function() {});
105+
"""
106+
When I run cypress with "-e tags=@a"
107+
Then it passes

0 commit comments

Comments
 (0)