Your configFile is invalid: ...magento2-cypress-testing-suite/cypress.config.js
It threw an error when required, check the stack trace below:
Error [ERR_REQUIRE_ESM]: require() of ES Module ...magento2-cypress-testing-suite/node_modules/del/index.js from ...magento2-cypress-testing-suite/cypress.config.js not supported.
Instead change the require of index.js in /Volumes/CaseSensitive/Workspace/php-sites/mos-hyva-245/magento2-cypress-testing-suite/cypress.config.js to a dynamic import() which is available in all CommonJS modules.
The problem is that del@7.0.0 is a node module, not a library (see "type": "module", in the del package.json).
This means it needs to be used with import.
The most simple fix is to use const del = import('del');
However, I suggest removing the dependency, since deleting folders and files is a trivial problem - node offers all that is needed out of the box (since fs is already imported):
Describe the bug
The PR https://github.com/elgentos/magento2-cypress-testing-suite/pull/98 breaks the config with
The problem is that
del@7.0.0
is a node module, not a library (see"type": "module",
in the del package.json). This means it needs to be used withimport
. The most simple fix is to useconst del = import('del');
However, I suggest removing the dependency, since deleting folders and files is a trivial problem - node offers all that is needed out of the box (since fs is already imported):To Reproduce
Expected behavior Cypress runs tests
Screenshots