-
Notifications
You must be signed in to change notification settings - Fork 5
70 lines (55 loc) · 1.62 KB
/
tests.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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
name: Tests
on:
push:
branches: [ "master" ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ "master" ]
# Builds images for target boards.
permissions:
contents: read
jobs:
tests:
runs-on: ubuntu-latest
strategy:
matrix:
go: ['1.23']
node: [22.x]
timeout-minutes: 10
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Setup Go ${{ matrix.go }}
uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
with:
go-version: ${{ matrix.go }}
- name: Setup Node.JS ${{ matrix.node }}
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
node-version: ${{ matrix.node }}
cache: 'yarn'
- name: Yarn install
run: yarn install
- name: Cache tools
uses: actions/cache@v4
with:
path: |
./.tools
key: ${{ runner.os }}-aptre-tools-${{ hashFiles('**/go.sum') }}
- name: Build Javascript
run: yarn run build
- name: Test Go
run: make test
- name: Test Js
run: yarn test:js
- name: Lint Js
run: yarn run lint:js
- name: Lint Go
run: yarn run lint:go
- name: Depcheck Js
run: yarn run deps
- name: Install chrome
uses: browser-actions/setup-chrome@latest
# Issue: https://github.com/agnivade/wasmbrowsertest/issues/60
# Remove the || true once fixed.
- name: Test with chrome
run: make test-browser || true