Skip to content

Commit 3c45f84

Browse files
committed
CI: run all tests on linux and various OCaml versions
and run macOS stuff only for 5.1
1 parent 2e27600 commit 3c45f84

File tree

1 file changed

+24
-12
lines changed

1 file changed

+24
-12
lines changed

.github/workflows/main.yml

Lines changed: 24 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,7 @@ jobs:
1414
fail-fast: true
1515
matrix:
1616
os:
17-
- macos-latest
1817
- ubuntu-latest
19-
#- windows-latest
2018
ocaml-compiler:
2119
- '4.08'
2220
- '4.14'
@@ -32,23 +30,37 @@ jobs:
3230
ocaml-compiler: ${{ matrix.ocaml-compiler }}
3331
dune-cache: true
3432
allow-prerelease-opam: true
35-
3633
- run: opam install -t containers containers-data --deps-only
37-
if: matrix.os == 'ubuntu-latest'
34+
- run: opam exec -- dune build '@install'
35+
- run: opam exec -- dune runtest
3836

37+
compat:
38+
name: build
39+
timeout-minutes: 15
40+
strategy:
41+
fail-fast: true
42+
matrix:
43+
os:
44+
- macos-latest
45+
- ubuntu-latest
46+
#- windows-latest
47+
ocaml-compiler:
48+
- '5.1'
49+
50+
runs-on: ${{ matrix.os }}
51+
steps:
52+
- uses: actions/checkout@main
53+
- name: Use OCaml ${{ matrix.ocaml-compiler }}
54+
uses: ocaml/setup-ocaml@v2
55+
with:
56+
ocaml-compiler: ${{ matrix.ocaml-compiler }}
57+
dune-cache: true
58+
allow-prerelease-opam: true
3959
- run: |
4060
opam install -t containers --deps-only ;
4161
opam install containers-data --deps-only # no test deps
42-
if: matrix.os != 'ubuntu-latest'
43-
4462
- run: opam exec -- dune build '@install'
45-
46-
- run: opam exec -- dune runtest
47-
if: ${{ matrix.os == 'ubuntu-latest' }}
48-
4963
- run: opam exec -- dune runtest -j 1 -p containers # test only core on non-ubuntu platform
50-
if: ${{ matrix.os != 'ubuntu-latest' }}
51-
5264

5365
format:
5466
name: format

0 commit comments

Comments
 (0)