version: 2

jobs:
  build:
    docker:
      - image: circleci/node:9
      - image: circleci/mongo:3
      - image: redis:4@sha256:e8b87a5e1bd53cba9226fa71a2eba27b177e4f1b94167d4d86b0cf9987d65d69
      - image: circleci/postgres:10.6
        environment:
          POSTGRES_USER: accounts-js
          POSTGRES_DB: accounts-js-tests-e2e
    steps:
      - checkout
      - run: yarn install --frozen-lockfile
      - run: yarn run lerna bootstrap
      - run: yarn test
      - run: yarn codecov
      - run: cd examples/react-rest-typescript && yarn install --frozen-lockfile && yarn test
      - run: cd examples/rest-express-typescript && yarn install --frozen-lockfile && yarn test
      - run: cd examples/react-graphql-typescript && yarn install --frozen-lockfile && yarn test
      - run: cd examples/graphql-server-typescript && yarn install --frozen-lockfile && yarn test

version: 2

jobs:
  build:
    docker:
      - image: circleci/node:9
      - image: circleci/mongo:3
      - image: redis:4@sha256:d4eef66199e66049090f8bc90cdd1a5316613c33bff5f45fbe488e7f01c5abc9
      - image: circleci/postgres:10.6
        environment:
          POSTGRES_USER: accounts-js
          POSTGRES_DB: accounts-js-tests-e2e
    steps:
      - checkout
      - run: yarn install --frozen-lockfile
      - run: yarn run lerna bootstrap
      - run: yarn test
      - run: yarn codecov
      - run: cd examples/react-rest-typescript && yarn install --frozen-lockfile && yarn test
      - run: cd examples/rest-express-typescript && yarn install --frozen-lockfile && yarn test
      - run: cd examples/react-graphql-typescript && yarn install --frozen-lockfile && yarn test
      - run: cd examples/graphql-server-typescript && yarn install --frozen-lockfile && yarn test

Update redis:4 Docker digest to d4eef66
Update redis:4 Docker digest to d4eef66
