Install the plugin by running:
npm install --save-dev cypress-cucumber-preprocessor
Cypress Configuration
Add it to your plugins: Go to & update at cypress/plugins/index.js
const cucumber = require('cypress-cucumber-preprocessor').default
module.exports = (on, config) => {
on('file:preprocessor', cucumber())
}
Add support for feature files to your Cypress configuration at:
cypress.json
{
"testFiles": "**/*.feature"
}
Go back to package.Json and update under dependencies:
"cypress-cucumber-preprocessor": {
"nonGlobalStepDefinitions": true
}
Install vscode-icons plugin: File>Preferences>File Icon theme>Vscode Icons
Install Cucumber (Gherkin) Full Support: https://marketplace.visualstudio.com/items?itemName=alexkrechik.cucumberautocomplete