-
Notifications
You must be signed in to change notification settings - Fork 296
81 lines (67 loc) · 2.05 KB
/
main.yml
File metadata and controls
81 lines (67 loc) · 2.05 KB
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
name: Build and test
permissions: {}
on:
# When only Hugo docs change, this workflow is not required:
push:
paths-ignore:
- 'doc/**'
- '.github/workflows/hugo.yml'
pull_request:
schedule:
# run daily, this refreshes the cache
- cron: "13 2 * * *"
merge_group:
concurrency: # On new push, cancel old workflows from the same PR, branch or tag:
group: ${{ github.workflow }}-${{github.event_name}}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
ocaml-tests:
name: Run OCaml tests
strategy:
fail-fast: false
matrix:
runs-on: ["ubuntu-22.04"]
ocaml-version: ["4.14.2"]
experimental: [false]
include:
- runs-on: "ubuntu-22.04-arm"
ocaml-version: "4.14.2"
experimental: true
- runs-on: "ubuntu-22.04"
ocaml-version: "5.4.1"
experimental: true
continue-on-error: ${{ matrix.experimental }}
runs-on: ${{ matrix.runs-on }}
permissions:
contents: read
env:
# Ensure you also update test-sdk-builds
# when changing this value, to keep builds
# consistent
XAPI_VERSION: "v0.0.0"
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Setup XenAPI environment
uses: ./.github/workflows/setup-xapi-environment
with:
xapi_version: ${{ env.XAPI_VERSION }}
ocaml_version: ${{ matrix.ocaml-version }}
- name: Build
run: opam exec -- make
- name: Run tests
run: opam exec -- make test
- name: Check all code
run: opam exec -- make check
- name: Run stress tests
run: opam exec -- make stresstest
if: ${{ github.event_name == 'schedule' }}
- name: Make install smoketest
run: |
opam exec -- make install DESTDIR=$(mktemp -d)
- name: Check disk space
run: df -h || true
- name: Trim dune cache
run: opam exec -- dune cache trim --size=2GiB