-
Notifications
You must be signed in to change notification settings - Fork 29
Description
Microsoft.Testing.Platform for .NET will sometimes generate an "empty" TRX file containing no tests. The TRX file is valid according to the TRX specification, I believe, but contains no tests.
This happens if I set a filter on my test execution (dotnet-test
) and this filter happens to exclude all tests in one of the assemblies (DLLs). Microsoft.Testing.Platform will generate one TRX file per assembly. If one assembly has no tests (i.e., all tests in the assembly are skipped), the platform will still generate a TRX file, but it will contain no tests.
The test-reporting plugin cannot handle this. It will crash with the error message:
Error: td.UnitTest is not iterable
Here is a minimal working example that reproduces the problem: https://github.com/CAP-3Shape/MstTrx/actions/runs/14441752164/job/40493252607
I believe this is a bug in the test-reporting plugin. Do you agree?