-
Notifications
You must be signed in to change notification settings - Fork 4
48 lines (48 loc) · 1.33 KB
/
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
name: CI
'on':
push: {}
pull_request: {}
jobs:
mix-test:
name: Mix Test
runs-on: ubuntu-latest
env:
MIX_ENV: test
ELIXIR_ENV: test
steps:
- uses: actions/checkout@v3
- name: Cache deps
id: cache-deps
uses: actions/cache@v3
env:
cache-name: cache-elixir-deps
with:
path: deps
key: >-
${{ runner.os }}-mix-${{ env.MIX_ENV }}-${{ env.cache-name }}-${{
hashFiles('mix.lock') }}
restore-keys: |
${{ runner.os }}-mix-${{ env.MIX_ENV }}-${{ env.cache-name }}-
- name: Cache compiled build
id: cache-build
uses: actions/cache@v3
env:
cache-name: cache-compiled-build
with:
path: _build
key: >-
${{ runner.os }}-mix-${{ env.MIX_ENV }}-${{ env.cache-name }}-${{
hashFiles('mix.lock') }}
restore-keys: |
${{ runner.os }}-mix-${{ env.MIX_ENV }}-${{ env.cache-name }}-
${{ runner.os }}-mix-${{ env.MIX_ENV }}-
${{ runner.os }}-mix
- name: Set up Elixir
uses: erlef/setup-beam@v1
with:
elixir-version: 1.16.0
otp-version: 26.1.2
- name: Install dependencies
run: mix deps.get
- name: Run Elixir tests
run: mix test