Merge pull request #113 from highmobility/ds-allow-empty-sasl #245
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
permissions: | |
contents: read | |
env: | |
MIX_ENV: test | |
ELIXIR_VERSION: 1.13.4 | |
ERLANG_VERSION: 25.0 | |
jobs: | |
build: | |
name: Tests & Checks | |
runs-on: ubuntu-24.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Elixir | |
uses: erlef/setup-beam@5304e04ea2b355f03681464e683d92e3b2f18451 | |
with: | |
elixir-version: ${{ env.ELIXIR_VERSION }} | |
otp-version: ${{ env.ERLANG_VERSION }} | |
- name: Restore dependencies cache | |
uses: actions/cache@v4 | |
with: | |
path: deps | |
key: ${{ runner.os }}-${{ env.ELIXIR_VERSION }}-${{ env.ERLANG_VERSION }}-mix-${{ hashFiles('**/mix.lock') }} | |
restore-keys: ${{ runner.os }}-mix- | |
- uses: actions/cache@v4 | |
name: Restore/Cache _plts | |
id: dialyzer-plts-files | |
with: | |
path: _plts/ | |
key: ${{ runner.os }}-${{ env.ELIXIR_VERSION }}-${{ env.ERLANG_VERSION }}-dialyzer-plts-files-01-${{ hashFiles(format('{0}{1}', github.workspace, '/mix.lock')) }} | |
restore-keys: | | |
${{ runner.os }}-${{ env.ELIXIR_VERSION }}-${{ env.ERLANG_VERSION }}-dialyzer-plts-files-01-${{ hashFiles(format('{0}{1}', github.workspace, '/mix.lock')) }} | |
- name: Install dependencies | |
run: mix deps.get | |
- name: Run tests | |
run: | | |
mix compile --warnings-as-errors | |
mix test | |
- name: Run formatter | |
run: | | |
mix format --check-formatted | |
- name: Run Credo | |
run: | | |
mix credo | |
- name: Run dialyzer | |
run: | | |
mkdir -p _plts | |
mix dialyzer |