TUnit icon indicating copy to clipboard operation
TUnit copied to clipboard

Tests not discovered in Test Explorer

Open silkfire opened this issue 4 months ago • 4 comments

I'm trying to run my tests in Visual Studio but unfortunately they're not discovered and there are no buttons in the gutter like there are for other testing frameworks.

Test Explorer says that 4 tests are found, but no tests are shown and the console contradictingly says "No tests found to run."

My testing project only has TUnit installed, no other packages.

Is this a bug in VS?

Also, in the documentation for TUnit, this option no longer exists (I assume because it's already enabled implicitly?):

Image
Image Image
namespace Tests
{
    public class MyTest
    {
        [Test]
        public async Task TestMethod()
        {
            await Assert.That(3).IsEqualTo(3);
        }
    }
}

silkfire avatar Oct 08 '25 09:10 silkfire

Yeah sounds like a VS issue

thomhurst avatar Oct 08 '25 09:10 thomhurst

I also noticed that all TUnit output goes to a log file located under TestResults. Is there a way to get all the output to the console instead?

silkfire avatar Oct 08 '25 11:10 silkfire

@silkfire Use --output Detailed

thomhurst avatar Oct 23 '25 14:10 thomhurst

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

github-actions[bot] avatar Nov 27 '25 00:11 github-actions[bot]

This issue was closed because it has been stalled for 5 days with no activity.

github-actions[bot] avatar Dec 02 '25 00:12 github-actions[bot]