Guide
Diagnosing Rider Unit Test Discovery Failures in .NET Solutions
Step-by-step diagnostic guide for when Rider’s Unit Test window fails to discover .NET tests, covering SDK references, target framework, test runner settings, and cache corruption.
Published by Tasadduq Burney
18 Jul 2026, 15:02 UTC
3 min19.5K views0

Recognizable condition
After building a .NET solution in Rider, the Unit Test window shows no tests, lists them as Skipped, or fails to refresh even when dotnet test succeeds from the terminal.
Cause / diagnostic table
| Possible cause | Typical symptom |
|---|---|
Test project missing Microsoft.NET.Test.Sdk reference |
Tests are not discovered; the window stays empty. |
| Target framework mismatch between test project and solution SDK | Tests appear as Skipped or the test runner reports an unsupported framework. |
| Rider’s built-in test runner disabled or outdated | Unit Test window shows a warning icon; no tests are listed after a build. |
Corrupted .idea caches |
Tests were visible before but disappear after a Rider restart or IDE update. |
Ordered checks
-
Verify the test SDK reference
- Open the test project’s
.csprojfile in Rider. - Look for a
PackageReferenceelement that includesMicrosoft.NET.Test.Sdk. - If the element is missing or the version is older than the current stable release (e.g.,
<Version>17.0.0</Version>), note this as a finding.
- Open the test project’s
-
Confirm target framework alignment
- In the same
.csproj, locate the<TargetFramework>tag. - Compare its value (e.g.,
net6.0) with the SDK version Rider is using (found viaHelp > About). - If they differ, record the mismatch.
- In the same
-
Check Rider’s test runner settings
- Navigate to
Settings/Preferences > Tools > Unit Testing. - Ensure the checkbox
Enable Rider unit test runneris ticked. - If disabled, enable it and note the setting.
- Navigate to
-
Inspect IDE caches
- Select
File > Invalidate Caches and Restart…. - After Rider restarts, observe whether the Unit Test window repopulates.
- If tests reappear, the cache was likely corrupted.
- Select
Fixes tied to findings
- Missing test SDK: Add the following line inside the
<ItemGroup>of the test project’s.csproj(adjust version as needed):
Save the file, let Rider restore packages, then rebuild.<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.0.0" /> - Target framework mismatch: Change the
<TargetFramework>value to match the solution’s SDK (e.g.,<TargetFramework>net6.0</TargetFramework>). Ensure all referenced projects support that framework; otherwise update them as well. Rebuild after saving. - Test runner disabled: Toggle the
Enable Rider unit test runneroption, clickApply, and restart Rider if prompted. - Corrupted caches: After invalidating caches (see step 4 above), Rider will rebuild its indices. No further action is required unless the problem persists.
Verification
- Rebuild the solution (
Build > Rebuild Solution). - Open the Unit Test window (
View > Tool Windows > Unit Test). - Confirm that tests appear with icons indicating
Not RunorPassed, notSkipped. - Run a single test via the gutter icon to ensure execution works and output appears in the Run window.
- Perform a clean build (
Build > Clean Solution) followed by a rebuild to ensure the issue does not reappear immediately.
Escalation criteria
If after completing all checks and applying the corresponding fixes the Unit Test window still shows no tests or continues to mark them as skipped:
- Collect Rider logs via
Help > Diagnostic Tools > Show Log in Explorerand reproduce the issue with a minimal solution containing only the problematic test project. - Attach the logs, the
.csprojfiles, and a description of the environment (Rider version, OS, .NET SDK version) to a support ticket at JetBrains. - Only escalate after the local diagnostics have been exhausted, as the support team will need the logs to identify deeper configuration or plugin conflicts.
0 replies
A thoughtful contribution can make all the difference. Be the first to share one.