Update to version 4 of cache and codecov actions #158
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: | |
- master | |
pull_request: | |
branches: | |
- master | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
otps: | |
name: OTP ${{ matrix.otp }} | |
runs-on: ubuntu-latest | |
container: erlang:${{ matrix.otp }} | |
strategy: | |
matrix: | |
otp: | |
- "26.2" | |
- "26.0" | |
- "25.3" | |
- "25.0" | |
- "24.3" | |
- "24.0" | |
- "23.2" | |
- "23.0" | |
- "22.3" | |
- "21.3" | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Cache .plt directory | |
uses: actions/cache@v4 | |
with: | |
path: .plt | |
key: ${{ runner.os }}-otp-${{ matrix.otp }} | |
- name: Test everything | |
run: make all | |
examples: | |
name: Test examples | |
runs-on: ubuntu-latest | |
container: erlang:26.2 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Test examples | |
run: make test-examples | |
parallel-examples: | |
name: Test examples in parallel | |
runs-on: ubuntu-latest | |
container: erlang:26.2 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Test examples in parallel | |
run: make test-parallel | |
coverage: | |
name: Code coverage | |
runs-on: ubuntu-latest | |
container: erlang:26.2 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Measure coverage | |
run: make test | |
env: | |
COVER: true | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v4 | |
with: | |
files: "_build/test/covertool/proper.covertool.xml" |