Skip to content

Replace plug.cowboy by plug (#95) #410

Replace plug.cowboy by plug (#95)

Replace plug.cowboy by plug (#95) #410

Workflow file for this run

name: Elixir CI
on: [push, pull_request]
jobs:
build:
name: Build and test
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
- elixir: '1.10'
otp: '21'
- elixir: '1.10'
otp: '22'
- elixir: '1.10'
otp: '23'
- elixir: '1.11'
otp: '21'
- elixir: '1.11'
otp: '22'
- elixir: '1.11'
otp: '23'
- elixir: '1.11'
otp: '24'
- elixir: '1.12'
otp: '22'
- elixir: '1.12'
otp: '23'
- elixir: '1.12'
otp: '24'
- elixir: '1.12'
otp: '24'
- elixir: '1.13'
otp: '22'
- elixir: '1.13'
otp: '23'
- elixir: '1.13'
otp: '24'
- elixir: '1.14'
otp: '23'
- elixir: '1.14'
otp: '24'
- elixir: '1.14'
otp: '25'
- elixir: '1.15'
otp: '24'
- elixir: '1.15'
otp: '25'
- elixir: '1.15'
otp: '26'
- elixir: '1.16'
otp: '24'
- elixir: '1.16'
otp: '25'
- elixir: '1.16'
otp: '26'
- elixir: '1.17'
otp: '25'
- elixir: '1.17'
otp: '26'
- elixir: '1.17'
otp: '27'
- elixir: '1.17'
otp: '27'
deps: latest
lint: lint
steps:
- uses: actions/checkout@v2
- uses: nanasess/setup-chromedriver@v2
- name: Set up Elixir
uses: erlef/setup-beam@v1
with:
elixir-version: ${{ matrix.elixir }}
otp-version: ${{ matrix.otp }}
- name: Retrieve Mix Dependencies Cache
if: matrix.deps != 'latest'
uses: actions/cache@v1
id: mix-cache
with:
path: deps
key: ${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}-mix-${{ hashFiles('mix.lock') }}
- name: Remove mix.lock
if: matrix.deps == 'latest'
run: rm mix.lock
- name: Install dependencies
if: steps.mix-cache.outputs.cache-hit != 'true'
run: mix deps.get
- name: Retrieve PLT Cache
uses: actions/cache@v1
id: plt-cache
with:
path: priv/plts
key: ${{ runner.os }}-${{ matrix.otp }}-${{ matrix.elixir }}-plts-v2-${{ hashFiles('mix.lock') }}
if: ${{ matrix.lint }}
- name: Create PLTs
run: |
mkdir -p priv/plts
mix dialyzer --plt
if: ${{ matrix.lint }}
- name: Check quality
run: |
mix format --check-formatted
mix credo --strict
mix dialyzer --no-check
if: ${{ matrix.lint }}
- name: Run tests
run: mix test
- name: Run e2e test
run: mix e2e
if: matrix.deps == 'latest'