2021-02-05 13:55:52 +00:00
|
|
|
name: Run tests on PR
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
branches:
|
2021-02-05 14:00:06 +00:00
|
|
|
- main
|
2021-02-05 13:55:52 +00:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
test:
|
|
|
|
name: Run tests
|
2021-10-18 14:52:55 +00:00
|
|
|
runs-on: ubuntu-latest
|
2021-02-05 13:55:52 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout code
|
|
|
|
uses: actions/checkout@v2
|
2021-02-19 10:40:06 +00:00
|
|
|
|
2021-02-05 13:55:52 +00:00
|
|
|
- name: Setup Node
|
|
|
|
uses: actions/setup-node@v1
|
2021-02-15 11:11:22 +00:00
|
|
|
with:
|
2021-10-15 13:14:51 +00:00
|
|
|
node-version: '14.17.6'
|
2021-02-05 13:55:52 +00:00
|
|
|
|
2021-02-19 10:40:06 +00:00
|
|
|
- name: Setup timezone
|
|
|
|
uses: zcong1993/setup-timezone@master
|
|
|
|
with:
|
|
|
|
timezone: Europe/Stockholm
|
|
|
|
|
2021-02-05 13:55:52 +00:00
|
|
|
- name: Install dependencies
|
2021-10-06 20:09:55 +00:00
|
|
|
run: yarn
|
|
|
|
|
2021-12-01 09:02:21 +00:00
|
|
|
- name: Run lint
|
2021-02-21 15:43:24 +00:00
|
|
|
run: |
|
2021-12-01 09:02:21 +00:00
|
|
|
yarn lint
|
2021-02-05 13:55:52 +00:00
|
|
|
env:
|
|
|
|
CI: true
|
2021-12-01 09:02:21 +00:00
|
|
|
|
|
|
|
- name: Run tests
|
|
|
|
run: |
|
|
|
|
yarn test
|
|
|
|
env:
|
|
|
|
CI: true
|