-
Notifications
You must be signed in to change notification settings - Fork 17
66 lines (63 loc) · 1.67 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
---
name: Tests
on:
push:
branches:
- main
- release/*
pull_request:
branches:
- main
jobs:
tests:
env:
MIX_ENV: test
MJML_BUILD: true
runs-on: ubuntu-latest
name: "[${{matrix.otp}}/${{matrix.elixir}}] Tests on mjml_nif [OTP/Elixir]"
strategy:
fail-fast: false
# For compatibility between Elixir & Erlang/OTP see
# https://hexdocs.pm/elixir/compatibility-and-deprecations.html#compatibility-between-elixir-and-erlang-otp
matrix:
otp: [24.3, 25.3, 26.2, 27.0]
elixir: [1.13.4, 1.14.5, 1.15.8, 1.16.3, 1.17.2]
exclude:
- otp: 26.2
elixir: 1.13.4
- otp: 27.0
elixir: 1.13.4
- otp: 27.0
elixir: 1.14.5
- otp: 27.0
elixir: 1.15.8
- otp: 27.0
elixir: 1.16.3
- otp: 24.3
elixir: 1.17.2
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
- uses: erlef/setup-beam@v1
with:
otp-version: ${{matrix.otp}}
elixir-version: ${{matrix.elixir}}
- name: Cache hex deps
id: mix-cache
uses: actions/cache@v4
with:
path: |
deps
_build
!_build/*/lib/mjml
key: ${{ runner.os }}[${{ matrix.otp }}/${{ matrix.elixir }}]-mix-${{ hashFiles(format('{0}{1}', github.workspace, '/mix.lock')) }}
- run: mix deps.get
- run: mix deps.compile
- run: mix compile --warnings-as-errors
env:
RUST_BACKTRACE: 1
- run: mix test