Test ❯ Edge #80
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: Test ❯ Edge | |
# Runs tests against edge versions of Erlang/OTP and Elixir | |
# to get ahead of incompatible changes. | |
on: | |
# Allow running from GitHub UI. | |
workflow_dispatch: {} | |
# Run daily. | |
schedule: | |
- cron: 0 0 * * * | |
env: | |
edge-elixir: "master" | |
edge-otp: "x" | |
MIX_ENV: test | |
concurrency: | |
group: test-edge-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
tests: | |
name: Testing Edge | |
runs-on: ${{ vars.PREFERRED_OS }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Erlang & Elixir | |
id: beam-versions | |
uses: erlef/setup-beam@v1 | |
with: | |
elixir-version: ${{ env.edge-elixir }} | |
otp-version: ${{ env.edge-otp }} | |
- name: Unlock dependencies | |
run: mix deps.unlock --all | |
- name: Install mix dependencies | |
run: mix deps.get | |
- name: Compile mix dependencies | |
run: mix deps.compile | |
- name: Run test suite | |
run: mix test | |
types: | |
# Skip type checking for now | |
if: ${{ !always() }} | |
name: Typechecking Edge | |
runs-on: ${{ vars.PREFERRED_OS }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Erlang & Elixir | |
id: beam-versions | |
uses: erlef/setup-beam@v1 | |
with: | |
elixir-version: ${{ env.edge-elixir }} | |
otp-version: ${{ env.edge-otp }} | |
- name: Unlock dependencies | |
run: mix deps.unlock --all | |
- name: Install mix dependencies | |
run: mix deps.get | |
- name: Compile mix dependencies | |
run: mix deps.compile | |
- name: Run typecheck tasks | |
run: mix typecheck | |
lints: | |
name: Linting Edge | |
runs-on: ${{ vars.PREFERRED_OS }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Erlang & Elixir | |
id: beam-versions | |
uses: erlef/setup-beam@v1 | |
with: | |
elixir-version: ${{ env.edge-elixir }} | |
otp-version: ${{ env.edge-otp }} | |
- name: Unlock dependencies | |
run: mix deps.unlock --all | |
- name: Install mix dependencies | |
run: mix deps.get | |
- name: Compile mix dependencies | |
run: mix deps.compile | |
- name: Run linter tasks | |
run: mix lint | |
continue-on-error: true | |
results: | |
name: Test Edge Action Results | |
runs-on: ${{ vars.PREFERRED_OS }} | |
if: ${{ always() }} | |
needs: | |
- tests | |
- types | |
- lints | |
steps: | |
- name: Test Suite Succeeded | |
if: ${{ needs.tests.result == 'success' && needs.types.result == 'success' && needs.lints.result == 'success' }} | |
run: exit 0 | |
- name: Test Suite Failed | |
if: ${{ needs.tests.result == 'failure' || needs.types.result == 'failure' || needs.lints.result == 'failure' }} | |
run: exit 1 |