-
Notifications
You must be signed in to change notification settings - Fork 3
95 lines (80 loc) · 2.04 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
name: Test
on:
push:
branches:
- main
paths:
- 'src/**'
- 'include/**'
- 'test/src/**'
- 'test/reference/**'
- 'Makefile'
- '*.mk'
- 'test/Makefile'
- '.github/workflows/test.yml'
pull_request:
paths:
- 'src/**'
- 'include/**'
- 'test/src/**'
- 'test/reference/**'
- 'Makefile'
- '*.mk'
- 'test/Makefile'
- '.github/workflows/test.yml'
jobs:
test:
name: Test and coverage
runs-on: ubuntu-latest
env:
CC: gcc
steps:
- uses: actions/checkout@v4
- name: install dependencies
run: sudo apt-get install -y lcov
- name: Run regression tests
run: make test
- name: Generate coverage data
run: make coverage
- name: Upload coverage to Codecov.io
uses: codecov/codecov-action@v4
continue-on-error: true
with:
fail_ci_if_error: false
flags: unittests
name: codecov
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
- name: Upload coverage to Coveralls.io
continue-on-error: true
uses: coverallsapp/github-action@v2
test-platforms:
name: ${{ matrix.arch }}
# The host should always be linux
runs-on: ubuntu-latest
# Run steps on a matrix of 4 arch/distro combinations
strategy:
matrix:
include:
- arch: armv7
distro: ubuntu_latest
- arch: aarch64
distro: ubuntu_latest
- arch: riscv64
distro: ubuntu_latest
- arch: s390x
distro: ubuntu_latest
- arch: ppc64le
distro: ubuntu_latest
steps:
- uses: actions/checkout@v4
- uses: uraimo/run-on-arch-action@v2
name: Run regression tests
id: test
with:
arch: ${{ matrix.arch }}
distro: ${{ matrix.distro }}
install: |
apt-get update -q -y
apt-get install -q -y make gcc gfortran
run: make test