Skip to content

Merge pull request #542 from movableink/nicksteffens/bump-prettier/pe… #1428

Merge pull request #542 from movableink/nicksteffens/bump-prettier/pe…

Merge pull request #542 from movableink/nicksteffens/bump-prettier/pe… #1428

Workflow file for this run

name: CI
on: [push, pull_request]
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: volta-cli/action@v1
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
- uses: actions/cache@v2
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install Dependencies
run: yarn install
- name: Prevent Duplicate Dependencies
run: yarn dedupe --check
- name: Run ESLint
run: yarn lint
- name: Check Non-JS files
run: yarn prettier --check "**/*.{json,md,yml}"
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: volta-cli/action@v1
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
- uses: actions/cache@v2
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install Dependencies
run: yarn install
- name: Run Jest
run: yarn test
env:
CI: true