Skip to content

Docs: .NET 10 'dotnet test' needs TestingPlatformDotnetTestSupport + global.json runner opt-in (README M.T.P. section) #20

Description

@StevenTCramer

Context

Found during TimeWarp.Architecture task 134 spike (TimeWarp.Jaribu/TimeWarp.Jaribu.TestingPlatform 1.0.0-beta.13, .NET 10 SDK 10.0.301).

Gap

Getting a JARIBU_MULTI aggregator project discovered by dotnet test on .NET 10 required TWO opt-ins, neither documented in the README's M.T.P. section:

  1. Per-project MSBuild property: <TestingPlatformDotnetTestSupport>true</TestingPlatformDotnetTestSupport>
  2. A global.json opt-in that cannot live in the csproj:
{ "test": { "runner": "Microsoft.Testing.Platform" } }

(.NET 10 removed the VSTest bridge, so without these, dotnet test fails.)

Two landmines worth explicit callouts

  • A project-local global.json added for the runner opt-in must mirror the repo's sdk pin — a global.json without an sdk section silently changed which installed SDK built the tree (picked a newer preview SDK) and broke unrelated projects with unrelated analyzer errors before we pinned it.
  • Invocation form matters: bare dotnet test from inside the project directory works, but dotnet test <path-to-csproj> (and --project <path>) fails with Testing with VSTest target is no longer supported by Microsoft.Testing.Platform on .NET 10 SDK and later. Tooling that shells out per-project with an explicit csproj path (CI scripts, task runners) hits this. Documenting the supported invocation forms would save consumers the same hour.

Request

Extend the README M.T.P. section with both opt-ins, the sdk-pin warning, and the supported dotnet test invocation forms on .NET 10.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions