Nimblesite / Nimblesite/SharpLsp

[Feature]: Microsoft.Testing.Platform (MTP) support in Test Explorer

Open
#249 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
132
Forks
5
Avg merge
6h 24m
Merged PRs (30d)
27

Description

Problem / motivation

The Test Explorer is VSTest end-to-end (dotnet test --list-tests, dotnet vstest --ListFullyQualifiedTests, dotnet test --filter … --logger trx, TRX parsing). MTP-only projects get only the degraded DisplayName fallback (TEST-EXPLORER-SPEC.md mentions MTP once), and runs fail.

This is becoming the common case: on .NET 10 SDK, MTP v2 removed the VSTest target shim, and xunit.v3 4.0.0 defaults to MTP v2. Concretely broken against an MTP-only project:

  • Discovery pass 1 (dotnet test --list-tests --nologo) — --nologo is rejected in MTP mode (exit code 5, zero tests; verified locally).
  • Discovery pass 2 (dotnet vstest <assembly>) — cannot load an MTP-only assembly.
  • Execution (--filter FullyQualifiedName=, --logger trx) — these don't exist in MTP mode (MTP uses --filter-class etc. / --report-trx).

Repro: .NET 10 SDK, xUnit v3 project (xunit.v3 4.0.0, <UseMicrosoftTestingPlatformRunner>true</UseMicrosoftTestingPlatformRunner>), global.json with {"test": {"runner": "Microsoft.Testing.Platform"}}, open in VS Code with SharpLsp.

Proposed solution

Detect MTP projects (Microsoft.Testing.Platform reference or test.runner: Microsoft.Testing.Platform in global.json) and switch them to an MTP path: MTP-mode dotnet test --list-tests for discovery, framework filter options for runs, TRX-report extension (or MTP result protocol) for outcomes. Happy to provide a sample repo or test a preview build.

Language relevance

Both C# and F#

Alternatives considered

Running tests via CLI outside the Testing view (works, but loses the explorer); Visual Studio / Rider / C# Dev Kit already run MTP projects in their Test Explorers.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with TEST-EXPLORER-SPEC.md and locate the existing VSTest discovery, execution, filtering, and TRX parsing paths. Reproduce the failures with the listed dotnet test and dotnet vstest commands; done means MTP-only projects are detected, discovered, run with the appropriate filters, and their outcomes appear in Test Explorer.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp, fsharp, typescript
Domain
devtools, testing-qa
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.