Skip to content

Instantly share code, notes, and snippets.

@petermenocal
Created November 9, 2017 17:06
Show Gist options
  • Save petermenocal/4433d0106200aba0bd53709e1bcbf433 to your computer and use it in GitHub Desktop.
Save petermenocal/4433d0106200aba0bd53709e1bcbf433 to your computer and use it in GitHub Desktop.
cypress + circleci config
version: 2
jobs:
build:
working_directory: ~/app
# The primary container is an instance of the first list image listed. Your build commands run in this container.
docker:
- image: cypress/base:8
environment:
TERM: xterm
steps:
- checkout
- restore_cache:
key: dependency-cache-{{ checksum "package.json" }}
- run:
name: Npm install
command: npm install
- save_cache:
key: dependency-cache-{{ checksum "package.json" }}
paths:
- node_modules
- run:
name: Spin up server
command: node index.js
background: true
- run:
name: Run tests
command: $(npm bin)/cypress run --record
- store_artifacts:
path: cypress/videos
- store_artifacts:
path: cypress/screenshots
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment