Last active
May 4, 2021 15:20
-
-
Save ondrej-janosik/d448055af45e74eca6e3a16862425070 to your computer and use it in GitHub Desktop.
Using NPM CI and Cypress with Bitbucket Pipelines
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
# Check out my blog post about this topic at https://medium.com/@ondrej.janosik42/setting-up-bitbucket-pipelines-with-proper-caching-of-npm-and-cypress-74d033888186 | |
image: node:10.8.0 | |
options: | |
max-time: 30 | |
pipelines: | |
default: | |
- step: | |
name: Install, build and tests | |
caches: | |
- npm | |
script: | |
- npm ci | |
- npm run build | |
- npm run test | |
- step: | |
name: E2E tests | |
caches: | |
- npm | |
- cypress | |
image: cypress/base:10 | |
script: | |
- npm ci | |
- npm run e2e | |
definitions: | |
caches: | |
npm: $HOME/.npm | |
cypress: $HOME/.cache/Cypress |
Hey there,
I ran your gist but got this error on pipeline:
bash: cypress: command not found
I've checked the base image and there's no installation for
cypress
there. Would you kindly help me with it?
Just add it to your own project npm install --save-dev cypress
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hey there,
I ran your gist but got this error on pipeline:
I've checked the base image and there's no installation for
cypress
there. Would you kindly help me with it?