Skip to content

Form 10215 (#967) #1134

Form 10215 (#967)

Form 10215 (#967) #1134

name: Build and Test
on: [push]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
build-and-test:
name: Build and Test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Get Node version
id: get-node-version
run: echo ::set-output name=NODE_VERSION::$(cat .nvmrc)
- name: Setup Node
uses: actions/setup-node@v2
with:
node-version: ${{ steps.get-node-version.outputs.NODE_VERSION }}
- name: Cache dependencies
id: cache-dependencies
uses: actions/cache@v2
with:
path: |
~/.cache/yarn
node_modules
key: ${{ steps.get-node-version.outputs.NODE_VERSION }}-${{ hashFiles('yarn.lock') }}
- name: Install dependencies
run: yarn install --frozen-lockfile --prefer-offline
env:
YARN_CACHE_FOLDER: ~/.cache/yarn
- name: Run Build
run: yarn build
- name: Run Yarn danger
run: yarn danger ci
- name: Run Tests
run: yarn test