pytest can output junit XML files and labgrid writes a console_main file with serial output. Let's collect both as artifacts of the build to make it easier to debug issues. Signed-off-by: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx> --- .github/workflows/test-labgrid-pytest.yml | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test-labgrid-pytest.yml b/.github/workflows/test-labgrid-pytest.yml index ae49decbaeae..6647237284d9 100644 --- a/.github/workflows/test-labgrid-pytest.yml +++ b/.github/workflows/test-labgrid-pytest.yml @@ -60,6 +60,22 @@ jobs: export KBUILD_OUTPUT=build-${{matrix.arch}} for i in ${{matrix.lgenv}}; do - echo "Testing $i" - labgrid-pytest --lg-env $i test/py --verbosity=1 --lg-log + cfg=$(basename $i .yaml) + echo "Testing $cfg" + labgrid-pytest --lg-env $i test/py --verbosity=1 \ + --junitxml=$cfg.tests.xml --lg-log=log/$cfg done + + - name: Publish Test Results + uses: EnricoMi/publish-unit-test-result-action@v2 + if: always() + with: + files: ./*.tests.xml + + - name: Publish Labgrid Log Results + uses: actions/upload-artifact@v3 + if: always() + with: + name: Console Logs + path: log/ + if-no-files-found: error -- 2.39.2