Skip to content

feat: add GitHub workflow for testing (#43) #5

feat: add GitHub workflow for testing (#43)

feat: add GitHub workflow for testing (#43) #5

Workflow file for this run

name: Elixir CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: read
jobs:
build:
name: Build and test Elixir ${{matrix.elixir}} / OTP ${{matrix.otp}}
runs-on: ubuntu-latest
strategy:
matrix:
otp: ['25.3', '26.0']
elixir: ['1.14', '1.15']
steps:
- uses: actions/checkout@v3
- name: Set up Elixir
uses: erlef/setup-beam@v1
with:
elixir-version: ${{matrix.elixir}}
otp-version: ${{matrix.otp}}
- name: Restore dependencies cache
uses: actions/cache@v3
with:
path: deps
key: ${{ runner.os }}-E${{matrix.elixir}}-O${{matrix.otp}}-mix-${{ hashFiles('**/mix.lock') }}
restore-keys: ${{ runner.os }}-E${{matrix.elixir}}-O${{matrix.otp}}-mix-
- name: Install dependencies
run: mix deps.get
- name: Run tests
run: mix test