From 8ab73d687d1ae56f280b4aa54e05bdf5c6485723 Mon Sep 17 00:00:00 2001 From: Benjamin Drung Date: Mon, 12 Feb 2024 22:55:33 +0100 Subject: [PATCH] ci: collect code coverage for install tests Include code coverage for `setup.py`. Signed-off-by: Benjamin Drung --- .github/workflows/ci.yaml | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 87bf666..83c4cf7 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -27,11 +27,20 @@ jobs: run: > apt-get update && apt-get install --no-install-recommends --yes - pandoc python3 python3-ruamel.yaml python3-setuptools + pandoc python3 python3-coverage python3-ruamel.yaml python3-setuptools - name: Run build - run: python3 setup.py build + run: python3 -m coverage run --branch setup.py build - name: Run install - run: python3 setup.py install + run: python3 -m coverage run -a --branch setup.py install + - name: Install dependencies for Codecov + run: > + apt-get install --no-install-recommends --yes + ca-certificates curl git + - name: Upload coverage to Codecov + uses: codecov/codecov-action@v3 + with: + fail_ci_if_error: true + files: ./coverage.xml unittest: runs-on: ubuntu-latest