Skip to content

Commit d3ed970

Browse files
committed
fix: Update to conduct full test matrix in actions
Updated to make sure that actions conduct testing for matrix of .NET versions.
1 parent fdb967e commit d3ed970

1 file changed

Lines changed: 7 additions & 4 deletions

File tree

.github/workflows/nuget-test-and-build.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ jobs:
5151
strategy:
5252
matrix:
5353
platform: [windows, ubuntu]
54+
dotnet-version: ['8.0.x', '9.0.x', '10.0.x']
5455
runs-on: ${{ matrix.platform }}-latest
5556
permissions:
5657
contents: write
@@ -68,18 +69,20 @@ jobs:
6869
- name: Setup .NET
6970
uses: actions/setup-dotnet@v4
7071
with:
71-
dotnet-version: 9.0.x
72+
dotnet-version: ${{ matrix.dotnet-version }}
73+
- name: Display dotnet version
74+
run: dotnet --version
7275
- name: Restore dependencies
7376
run: dotnet restore
7477
- name: Build
7578
run: dotnet build --no-restore --configuration release
7679
- name: Test
77-
run: dotnet test Kepware.Api.Test/Kepware.Api.Test.csproj --no-build --verbosity normal --configuration Release --logger "trx;LogFileName=${{ matrix.platform }}-test-results.trx"
78-
- name: Publish Test Report (${{ matrix.platform }})
80+
run: dotnet test Kepware.Api.Test/Kepware.Api.Test.csproj --no-build --verbosity normal --configuration Release --logger "trx;LogFileName=${{ matrix.platform }}-${{ matrix.dotnet-version }}-test-results.trx"
81+
- name: Publish Test Report (${{ matrix.platform }} .NET ${{ matrix.dotnet-version }})
7982
if: ${{ github.event_name == 'pull_request' }}
8083
uses: dorny/test-reporter@v1
8184
with:
82-
name: .NET 9 Test Report (${{ matrix.platform }})
85+
name: .NET ${{ matrix.dotnet-version }} Test Report (${{ matrix.platform }})
8386
path: "**/TestResults/**/*.trx"
8487
reporter: dotnet-trx
8588
- name: store NuGet package

0 commit comments

Comments
 (0)