-
Notifications
You must be signed in to change notification settings - Fork 27
55 lines (43 loc) · 1.21 KB
/
go-tests.yaml
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
name: Tests
on:
push:
paths:
- "**/*.go"
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
go-version: [ '1.18', '1.19', '1.20', '1.21' ]
env:
MUREX_BUILD_FLAGS: --no-colour
MUREX_TEST_NO_EXEC_DEPS: true
steps:
- uses: actions/checkout@v3
- name: Setup Go ${{ matrix.go-version }}
uses: actions/setup-go@v4
with:
go-version: ${{ matrix.go-version }}
- name: Display Go version
run: |
go version
- name: Enable all optional builtins
run: |
rm -vf builtins/imports_build/*
cp -vf builtins/imports_src/* builtins/imports_build/
- name: Go Test
run: |
go test ./... -count 1 -race
- name: Build native target
run: |
go build -v github.com/lmorg/murex
- name: Behavioural tests
run: |
./murex -c 'g: behavioural/*.mx -> foreach: f { source $f }; test: run *'
- name: Build cross-compiled targets
run: |
./murex ./test/build_all_platforms.mx --no-colour
- name: Build web assembly target
run: |
GOOS=js GOARCH=wasm go build -o murex.wasm .