Skip to content

Commit

Permalink
Add CI
Browse files Browse the repository at this point in the history
  • Loading branch information
reachfh committed Oct 21, 2023
1 parent a2ae59e commit 07d934d
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
name: Test
on:
push:
branches:
- "main"
pull_request:
jobs:
test:
name: Run tests
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
otp: ['24.3', '25.2', '26.1.2']
steps:
- name: Cancel previous runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- name: Check out source
uses: actions/checkout@v3

- name: Install Erlang and Elixir
uses: erlef/setup-beam@v1
with:
otp-version: ${{matrix.otp}}
rebar3-version: '3.18.0'

- name: Retrieve cached deps
uses: actions/cache@v3
with:
path: |
_build
key: ${{ matrix.otp }}-${{ hashFiles('**/rebar.lock') }}
restore-keys: |
${{ matrix.otp }}-
- name: Check formatting
run: rebar3 steamroll --check

- name: Run Erlang tests
run: rebar3 ct

- name: Run static code analysis checks
run: rebar3 dialyzer

0 comments on commit 07d934d

Please sign in to comment.