-
Notifications
You must be signed in to change notification settings - Fork 12
46 lines (36 loc) · 1002 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
name: CI
on:
pull_request:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
name: Elixir ${{ matrix.elixir }} / OTP ${{ matrix.otp }}
strategy:
matrix:
elixir: ['1.13']
otp: ['24.x']
steps:
- uses: actions/checkout@v2
- name: Setup BEAM
uses: erlef/setup-beam@v1
with:
elixir-version: ${{ matrix.elixir }}
otp-version: ${{ matrix.otp }}
- name: Restore dependencies cache
uses: actions/cache@v2
id: cache-elixir-deps
with:
path: |
deps
_build
key: ${{ runner.os }}-mix-${{ hashFiles('**/mix.lock') }}-${{ matrix.otp }}
- name: Install Dependencies
if: steps.cache-elixir-deps.outputs.cache-hit != 'true'
run: MIX_ENV=test mix do deps.get, deps.compile, compile
- run: mix format --check-formatted
if: matrix.elixir == '1.13'
- name: Run Tests
run: mix test