mirror of
https://github.com/iustin/mt-st.git
synced 2026-04-23 13:10:28 +00:00
Switch to more recent versions of the checkout and codecov action, the latter also removing saving the data locally, so remove the archival of that data.
65 lines
1.2 KiB
YAML
65 lines
1.2 KiB
YAML
on:
|
|
# Trigger the workflow on push or
|
|
# pull request, but only for the
|
|
# main branch.
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
# Weekly run to account for
|
|
# changed dependencies.
|
|
schedule:
|
|
- cron: '17 04 * * 0'
|
|
|
|
name: CI
|
|
jobs:
|
|
build:
|
|
name: Build and test
|
|
runs-on: ${{ matrix.os }}
|
|
strategy:
|
|
matrix:
|
|
os: [ubuntu-latest]
|
|
compiler: ['gcc', 'clang']
|
|
fail-fast: false
|
|
env:
|
|
CC: ${{ matrix.compiler }}
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Build the code
|
|
run: make
|
|
|
|
- name: Test creating the release archive
|
|
run: make distcheck
|
|
|
|
coverage:
|
|
name: Check code coverage
|
|
runs-on: ubuntu-latest
|
|
env:
|
|
CC: gcc
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Install dependencies
|
|
run: sudo apt-get install -yy shelltestrunner
|
|
|
|
- name: Build the code
|
|
run: make CFLAGS=-coverage
|
|
|
|
- name: Run tests under coverage
|
|
run: make check
|
|
|
|
- name: Upload coverage to Codecov
|
|
uses: codecov/codecov-action@v3
|
|
with:
|
|
name: codecov-gcc
|
|
#fail_ci_if_error: true
|
|
verbose: true
|
|
gcov: true
|