From b0a7e9211f7a3a7883efb6aeffafc41e8e65eafa Mon Sep 17 00:00:00 2001 From: Robert Sachunsky <38561704+bertsky@users.noreply.github.com> Date: Wed, 3 Jul 2024 22:25:16 +0200 Subject: [PATCH] CI: store pytest results, use flake8 github formatting --- .github/workflows/unit-test.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/unit-test.yml b/.github/workflows/unit-test.yml index 2b8e3d5b8..2ab5ee46c 100644 --- a/.github/workflows/unit-test.yml +++ b/.github/workflows/unit-test.yml @@ -50,14 +50,18 @@ jobs: make install deps-test - name: Test with pytest run: | - make test benchmark + mkdir -p test-results + make test benchmark PYTEST_ARGS=--junitxml=test-results/test.xml + - uses: test-summary/action@v2 + with: + paths: "test-results/test.xml" - name: test to ensure that --editable install works run: | make install-dev; ocrd --version - name: Lint with flake8 run: | - python -m pip install flake8 + python -m pip install flake8 flake8-github # stop the build if there are Python syntax errors or undefined names - flake8 src --count --exit-zero --select=E9,F63,F7,F82 --show-source --statistics + flake8 src --count --exit-zero --select=E9,F63,F7,F82 --show-source --statistics --format=github # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide - flake8 src --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics + flake8 src --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics --format=github