mirror of
https://github.com/ppy/osu
synced 2024-12-13 10:28:17 +00:00
46 lines
1.4 KiB
YAML
46 lines
1.4 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:
|
|
contents: read
|
|
actions: read
|
|
checks: write
|
|
|
|
jobs:
|
|
annotate:
|
|
name: Annotate CI run with test results
|
|
runs-on: ubuntu-latest
|
|
if: ${{ github.event.workflow_run.conclusion != 'cancelled' }}
|
|
timeout-minutes: 5
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
repository: ${{ github.event.workflow_run.repository.full_name }}
|
|
ref: ${{ github.event.workflow_run.head_sha }}
|
|
|
|
- name: Download results
|
|
uses: actions/download-artifact@v4
|
|
with:
|
|
pattern: osu-test-results-*
|
|
merge-multiple: true
|
|
run-id: ${{ github.event.workflow_run.id }}
|
|
github-token: ${{ github.token }}
|
|
|
|
- name: Annotate CI run with test results
|
|
uses: dorny/test-reporter@v1.8.0
|
|
with:
|
|
name: Results
|
|
path: "*.trx"
|
|
reporter: dotnet-trx
|
|
list-suites: 'failed'
|
|
list-tests: 'failed'
|