osu/.github/workflows/report-nunit.yml
Mohammed Keyvanzadeh 3d032d0024
github: update workflows and make tweaks
- Update the GitHub Actions workflows to their latest versions.
- Replace the usage of the deprecated `set-output` command with the
new recommended way to set the output.
- Format the YAML files.
2023-03-27 18:10:32 +03:30

40 lines
1.3 KiB
YAML

# This is a workaround to allow PRs to report their coverage. This will run inside the base repository.
# See:
# * https://github.com/dorny/test-reporter#recommended-setup-for-public-repositories
# * https://docs.github.com/en/actions/reference/authentication-in-a-workflow#permissions-for-the-github_token
name: Annotate CI run with test results
on:
workflow_run:
workflows: ["Continuous Integration"]
types:
- completed
permissions: {}
jobs:
annotate:
permissions:
checks: write # to create checks (dorny/test-reporter)
name: Annotate CI run with test results
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion != 'cancelled' }}
strategy:
fail-fast: false
matrix:
os:
- { prettyname: Windows }
- { prettyname: macOS }
- { prettyname: Linux }
threadingMode: ["SingleThread", "MultiThreaded"]
timeout-minutes: 5
steps:
- name: Annotate CI run with test results
uses: dorny/test-reporter@v1.6.0
with:
artifact: osu-test-results-${{ matrix.os.prettyname }}-${{ matrix.threadingMode }}
name: Test Results (${{ matrix.os.prettyname }}, ${{ matrix.threadingMode }})
path: "*.trx"
reporter: dotnet-trx
list-suites: "failed"
list-tests: "failed"