Skip to content

CI housekeeping

CI housekeeping #199

Workflow file for this run

on:
pull_request:
push:
branches:
- master
name: tests
jobs:
test:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
- pair:
elixir: "1.13"
otp: "22"
- pair:
elixir: "1.17"
otp: "27"
lint: lint
env:
MIX_ENV: test
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v4
- uses: erlef/setup-beam@v1
with:
otp-version: ${{matrix.pair.otp}}
elixir-version: ${{matrix.pair.elixir}}
# - name: Cache deps
# uses: actions/cache@v4
# with:
# path: deps
# key: ${{ runner.os }}-deps-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('**/mix.lock') }}
# restore-keys: ${{ runner.os }}-deps-${{ matrix.otp }}-${{ matrix.elixir }}-
# - name: Cache build
# uses: actions/cache@v4
# with:
# path: _build
# key: ${{ runner.os }}-build-${{ matrix.otp }}-${{ matrix.elixir }}-${{ hashFiles('**/mix.lock') }}
# restore-keys: ${{ runner.os }}-build-${{ matrix.otp }}-${{ matrix.elixir }}-
- run: mix deps.get
- run: mix deps.unlock --check-unused
if: ${{ matrix.lint }}
- run: mix compile --warnings-as-errors
- run: mix format --check-formatted
if: ${{ matrix.lint }}
- run: mix credo --strict
if: ${{ matrix.lint }}
- run: mix coveralls.github
- run: mix dialyzer
if: ${{ matrix.lint }}