mirror of
https://github.com/systemd/systemd.git
synced 2024-11-01 00:51:24 +03:00
38 lines
1.2 KiB
YAML
38 lines
1.2 KiB
YAML
---
|
|
# vi: ts=2 sw=2 et:
|
|
# SPDX-License-Identifier: LGPL-2.1-or-later
|
|
#
|
|
name: Unit tests
|
|
on:
|
|
# On push/merge to main we only run the GCC job, to get coverage data uploaded to coveralls.io
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-20.04
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
run_phase: [GCC, GCC_ASAN_UBSAN, CLANG, CLANG_ASAN_UBSAN]
|
|
steps:
|
|
- name: Repository checkout
|
|
uses: actions/checkout@v2
|
|
if: github.event_name == 'pull_request' || matrix.run_phase == 'GCC'
|
|
- name: Install build dependencies
|
|
run: sudo -E .github/workflows/unit_tests.sh SETUP
|
|
if: github.event_name == 'pull_request' || matrix.run_phase == 'GCC'
|
|
- name: Build & test (${{ matrix.run_phase }})
|
|
run: sudo -E .github/workflows/unit_tests.sh RUN_${{ matrix.run_phase }}
|
|
if: github.event_name == 'pull_request' || matrix.run_phase == 'GCC'
|
|
- name: Coveralls
|
|
if: matrix.run_phase == 'GCC' && github.repository == 'systemd/systemd'
|
|
uses: coverallsapp/github-action@master
|
|
with:
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
path-to-lcov: ./build/meson-logs/coverage.info
|