Closed
Description
What happened:
grafana-e2e run
does not work and outputs
Command failed with ENOENT: /home/test/proj/Unknown command: "bin"
To see a list of supported npm commands, run:
npm help/cypress run --env CWD=/home/test/proj/,UPDATE_SCREENSHOTS=0 --project=/home/test/proj/node_modules/@grafana/e2e
spawn /home/test/proj/Unknown command: "bin"
To see a list of supported npm commands, run:
npm help/cypress ENOENT
What you expected to happen:
The command runs
How to reproduce it (as minimally and precisely as possible):
Create a new plugin using the plugin code gen and run npm run e2e
. Make sure npm is using version 9
Anything else we need to know?:
- @grafana/e2e uses resolve-as-bin to resolve the cypress bin path.
- The package uses
npm bin
command which is removed in npm @ 9 feat: removenpm bin
npm/cli#5459 - Because
npm bin
is removed,resolve-as-bin
will return an error
A temporary solution would be to downgrade to NPM 8
Metadata
Metadata
Assignees
Type
Projects
Status
🚀 Shipped