Skip to content

Commit 2b3aabf

Browse files
committed
fix(ci): remove Testing Platform mode entirely for .NET 10 SDK compatibility
The MSTest Testing Platform has protocol version issues with .NET 10.0.201 SDK. Instead of complex workarounds, simply use the standard VSTest adapter which works reliably with all SDK versions. Removed: - EnableMSTestRunner from csproj - TestingPlatformDotnetTestSupport from csproj - global.json (removed in previous commit) - Unnecessary -p: flags from workflow
1 parent aafbccc commit 2b3aabf

2 files changed

Lines changed: 3 additions & 14 deletions

File tree

.github/workflows/build-and-release.yml

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -41,14 +41,7 @@ jobs:
4141
dotnet-quality: 'preview'
4242

4343
- name: Build
44-
shell: bash
45-
run: |
46-
# Disable MSTest Testing Platform for CI due to .NET 10 SDK protocol version mismatch
47-
dotnet build test/NumSharp.UnitTest/NumSharp.UnitTest.csproj \
48-
--configuration Release \
49-
-p:NoWarn=${{ env.DOTNET_NOWARN }} \
50-
-p:EnableMSTestRunner=false \
51-
-p:TestingPlatformDotnetTestSupport=false
44+
run: dotnet build test/NumSharp.UnitTest/NumSharp.UnitTest.csproj --configuration Release -p:NoWarn=${{ env.DOTNET_NOWARN }}
5245

5346
# Test filtering:
5447
# - OpenBugs: excluded (known-failing bug reproductions)
@@ -65,9 +58,8 @@ jobs:
6558
if [[ "$RUNNER_OS" != "Windows" ]]; then
6659
FILTER="$FILTER&TestCategory!=WindowsOnly"
6760
fi
68-
dotnet test --project test/NumSharp.UnitTest/NumSharp.UnitTest.csproj \
61+
dotnet test test/NumSharp.UnitTest/NumSharp.UnitTest.csproj \
6962
--configuration Release --no-build --framework net8.0 \
70-
-p:EnableMSTestRunner=false -p:TestingPlatformDotnetTestSupport=false \
7163
--filter "$FILTER" --logger "trx"
7264
7365
- name: Test (net10.0)
@@ -81,9 +73,8 @@ jobs:
8173
if [[ "$RUNNER_OS" != "Windows" ]]; then
8274
FILTER="$FILTER&TestCategory!=WindowsOnly"
8375
fi
84-
dotnet test --project test/NumSharp.UnitTest/NumSharp.UnitTest.csproj \
76+
dotnet test test/NumSharp.UnitTest/NumSharp.UnitTest.csproj \
8577
--configuration Release --no-build --framework net10.0 \
86-
-p:EnableMSTestRunner=false -p:TestingPlatformDotnetTestSupport=false \
8778
--filter "$FILTER" --logger "trx"
8879
8980
- name: Upload Test Results

test/NumSharp.UnitTest/NumSharp.UnitTest.csproj

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@
99
<Platforms>AnyCPU</Platforms>
1010
<AssemblyOriginatorKeyFile>Open.snk</AssemblyOriginatorKeyFile>
1111
<Configurations>Debug;Release;Publish</Configurations>
12-
<EnableMSTestRunner>true</EnableMSTestRunner>
13-
<TestingPlatformDotnetTestSupport>true</TestingPlatformDotnetTestSupport>
1412
</PropertyGroup>
1513

1614
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Publish|AnyCPU'">

0 commit comments

Comments
 (0)