generated from gsmlg/elixir-package-template
-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (39 loc) · 979 Bytes
/
ci.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
name: CI
on:
pull_request:
branches: [ main ]
jobs:
tests:
name: Run tests (Elixir ${{ matrix.elixir }}, OTP ${{ matrix.otp }})
strategy:
matrix:
include:
- os: ubuntu-latest
elixir: 1.18
otp: 27
runs-on: ${{ matrix.os }}
env:
MIX_ENV: test
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Set up Elixir
uses: erlef/setup-beam@v1
with:
otp-version: ${{ matrix.otp }}
elixir-version: ${{ matrix.elixir }}
- name: Install dependencies
run: |
mix deps.get
bun install
- name: Check source code format
run: mix format --check-formatted
- name: Remove compiled application files
run: mix clean
- name: Compile & lint dependencies
run: mix compile --warnings-as-errors
- name: Run tests
run: mix test