-
Notifications
You must be signed in to change notification settings - Fork 25
52 lines (43 loc) · 1.13 KB
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: Test
on:
push:
branches: ['main']
pull_request:
branches: ['main']
jobs:
test:
runs-on: ${{ matrix.os }}
services:
mysql:
image: mysql:8.0
env:
MYSQL_ALLOW_EMPTY_PASSWORD: yes
MYSQL_DATABASE: nano_test
ports:
- 3306:3306
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
strategy:
matrix:
os: [ubuntu-latest]
steps:
- name: Check out Git repository
uses: actions/checkout@v1
- name: Install Node.js, NPM and Yarn
uses: actions/setup-node@v3
with:
node-version: current
# TODO: Fix checksum issue and remove env variable
- name: yarn install
run: |
YARN_CHECKSUM_BEHAVIOR=update yarn install
cd cli
YARN_CHECKSUM_BEHAVIOR=update yarn install
cd ..
- name: yarn lint
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: yarn lint
- name: yarn test
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: yarn test