version: 2 # use CircleCI 2.0
jobs: # a collection of steps
  build: # runs not using Workflows must have a `build` job as entry point
    working_directory: ~/mern-starter # directory where steps will run
    docker: # run the steps with Docker
      - image: node:latest
    steps: # a collection of executable commands
      - checkout # special step to check out source code to working directory
      - run:
          name: install
          command: npm ci
      - run: # run tests
          name: test
          command: npm run test-ci