Closed wawagit closed 4 years ago
I solved the problem by replacing lower case letters with upper case letters for given
, when
, then
as Given
, When
and Then
...
with:
import { Given, When, Then } from "cypress-cucumber-preprocessor/steps";
instead of:
const {given, when, then} = require('cypress-cucumber-preprocessor');
The lower case version was working well before installing cypress-plugin-snapshots
so it's a bit strange but it works fine now.
hope this help someone ;)
We are writing our specs using cucumber/gherkin syntax (w/h cypress-cucumber-preprocessor plugin). Everything works fine.
When I tried to init the cypress-plugin-snapshots plugin and running my tests I get the following error:
fs.readFileSync is not a function
To Reproduce
Steps to reproduce the behavior:
cypress/plugins/index.js
filecypress open
commandMy cypress/plugins.index.js file:
Expected behavior Be able to write cucumber like specs with working visual regression tests.
Did i set something wrong in my config?
Let me know if i can help to identify the problem. Thanks :)