Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions .github/workflows/test-report.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: ci-report

# See Dorny instructions for why we need a separate yaml for creating a test report
# for public repositories that accept forks:
# https://github.com/dorny/test-reporter#recommended-setup-for-public-repositories

on:
workflow_run:
workflows: ci-test # runs after CI workflow
types:
- completed
jobs:
test-report-release:
runs-on: windows-latest
name: Test report (release)
steps:
- uses: dorny/test-reporter@v1
with:
artifact: test-results-release # artifact name
name: Dorny release tests # Name of the check run which will be created
path: '*.trx' # Path to test results (inside artifact .zip)
reporter: dotnet-trx # Format of test results

test-report-debug:
runs-on: windows-latest
name: Test report (debug)
steps:
- uses: dorny/test-reporter@v1
with:
artifact: test-results-debug # artifact name
name: Dorny debug tests # Name of the check run which will be created
path: '*.trx' # Path to test results (inside artifact .zip)
reporter: dotnet-trx # Format of test results
30 changes: 15 additions & 15 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@ name: ci-test

on: [pull_request]

permissions:
id-token: write
contents: read
checks: write

jobs:
test-release:
name: Test Release Build
Expand All @@ -17,20 +12,23 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0

# setup dotnet based on global.json
- name: setup-dotnet
uses: actions/setup-dotnet@v3

# build it, test it
- name: Run dotnet test - release
run: ./build.cmd ci -release
- name: Publish test results - release
uses: dorny/test-reporter@v1
if: always()

# upload test results
- uses: actions/upload-artifact@v2
if: success() || failure()
with:
name: Report release tests
name: test-results-release
# this path glob pattern requires forward slashes!
path: ./src/FSharp.Control.TaskSeq.Test/TestResults/test-results-release.trx
reporter: dotnet-trx


test-debug:
name: Test Debug Build
Expand All @@ -41,17 +39,19 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0

# setup dotnet based on global.json
- name: setup-dotnet
uses: actions/setup-dotnet@v3

# build it, test it
- name: Run dotnet test - debug
run: ./build.cmd ci -debug
- name: Publish test results - debug
uses: dorny/test-reporter@v1
if: always()

# upload test results
- uses: actions/upload-artifact@v2
if: success() || failure()
with:
name: Report debug tests
name: test-results-debug
# this path glob pattern requires forward slashes!
path: ./src/FSharp.Control.TaskSeq.Test/TestResults/test-results-debug.trx
reporter: dotnet-trx
1 change: 1 addition & 0 deletions src/FSharp.Control.TaskSeq.sln
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{
..\.github\dependabot.yml = ..\.github\dependabot.yml
..\.github\workflows\main.yaml = ..\.github\workflows\main.yaml
..\.github\workflows\publish.yaml = ..\.github\workflows\publish.yaml
..\.github\workflows\test-report.yaml = ..\.github\workflows\test-report.yaml
..\.github\workflows\test.yaml = ..\.github\workflows\test.yaml
EndProjectSection
EndProject
Expand Down