circleci-orb
circleci-orb copied to clipboard
Check first commands controlling the install
When doing effective config for file
version: 2.1
orbs:
cypress: cypress-io/cypress@1
workflows:
build:
jobs:
- cypress/run
and resolving orb to cypress-io/[email protected] I see weird "echo" and attach workspace commands at the start
- run:
command: echo "Assuming dependencies were installed using cypress/install job"
- attach_workspace:
at: ~/
Full effective config
version: 2
jobs:
cypress/run:
docker:
- image: cypress/base:10
parallelism: 1
environment:
- CYPRESS_CACHE_FOLDER: ~/.cache/Cypress
steps:
- run:
command: echo "Assuming dependencies were installed using cypress/install job"
- attach_workspace:
at: ~/
- checkout
- restore_cache:
keys:
- cache-{{ arch }}-{{ .Branch }}-{{ checksum "package.json" }}
- run:
name: Install
working_directory: ''
command: "if [[ ! -z \"\" ]]; then\n echo \"Installing using custom command\"\n echo \"\"\n \nelif [ \"false\" = \"true\" ]; then\n echo \"Installing using Yarn\"\n yarn install --frozen-lockfile\nelif [ ! -e ./package-lock.json ]; then\n echo \"The Cypress orb uses 'npm ci' to install 'node_modules', which requires a 'package-lock.json'.\"\n echo \"A 'package-lock.json' file was not found. Please run 'npm install' in your project,\"\n echo \"and commit 'package-lock.json' to your repo.\"\n exit 1\nelse\n echo \"Installing dependencies using NPM ci\"\n npm ci\nfi\n"
- run:
name: Verify Cypress
command: npx cypress verify
working_directory: ''
- save_cache:
key: cache-{{ arch }}-{{ .Branch }}-{{ checksum "package.json" }}
paths:
- ~/.npm
- ~/.cache
- persist_to_workspace:
root: ~/
paths:
- project
- .cache/Cypress
- run:
name: Run Cypress tests
no_output_timeout: 10m
command: "npx cypress run \\\n \\\n \\\n \\\n "
working_directory: ''
workflows:
build:
jobs:
- cypress/run
version: 2