forked from Klaveness-Digital/cypress-cucumber-preprocessor
-
-
Notifications
You must be signed in to change notification settings - Fork 148
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: cleanup and improvement for the significantly faster testrun fo…
…r all tests closes #189
- Loading branch information
Showing
10 changed files
with
89 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
exports.cucumberTemplate = ` | ||
const { | ||
resolveAndRunStepDefinition, | ||
defineParameterType, | ||
given, | ||
when, | ||
then, | ||
and, | ||
but, | ||
Before, | ||
After, | ||
defineStep | ||
} = require("cypress-cucumber-preprocessor/lib/resolveStepDefinition"); | ||
const Given = (window.Given = window.given = given); | ||
const When = (window.When = window.when = when); | ||
const Then = (window.Then = window.then = then); | ||
const And = (window.And = window.and = and); | ||
const But = (window.But = window.but = but); | ||
window.defineParameterType = defineParameterType; | ||
window.defineStep = defineStep; | ||
const { | ||
createTestsFromFeature | ||
} = require("cypress-cucumber-preprocessor/lib/createTestsFromFeature"); | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
const cosmiconfig = require("cosmiconfig"); | ||
const log = require("debug")("cypress:cucumber"); | ||
|
||
exports.getCucumberJsonConfig = () => { | ||
const explorer = cosmiconfig("cypress-cucumber-preprocessor", { sync: true }); | ||
const loaded = explorer.load(); | ||
|
||
const cucumberJson = | ||
loaded && loaded.config && loaded.config.cucumberJson | ||
? loaded.config.cucumberJson | ||
: { generate: false }; | ||
log("cucumber.json", JSON.stringify(cucumberJson)); | ||
|
||
return cucumberJson; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters