From eb3835612c883607823c2a35e7c97aef33fabb07 Mon Sep 17 00:00:00 2001 From: Volodymyr Dombrovskyi Date: Wed, 20 Sep 2023 19:38:56 +0300 Subject: [PATCH] add test reporting step to workflow --- .github/workflows/build.yml | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0b9bf4f..916bf18 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -11,8 +11,11 @@ on: jobs: build: - runs-on: ubuntu-latest + + permissions: + id-token: write + contents: read steps: - uses: actions/checkout@v3 @@ -25,4 +28,12 @@ jobs: - name: Build run: dotnet build --no-restore - name: Test - run: dotnet test --no-build --verbosity normal + run: dotnet test --no-build --verbosity normal --logger "trx;LogFileName=stage\test-results.trx" + - name: Test Report + uses: dorny/test-reporter@v1 + if: always() + with: + name: DotNET Tests + path: "**/test-results.trx" + reporter: dotnet-trx + fail-on-error: true