Rhino.Testing icon indicating copy to clipboard operation
Rhino.Testing copied to clipboard

0 of 6 tests run, The active test run was aborted. Reason: Test host process crashed

Open Sonderwoods opened this issue 1 year ago • 0 comments

Hi @eirannejad ,

I'm trying to run the SimpleRhinoTests, directly cloned.

I'm getting the below "errors" although 0 tests will run.

========== Starting test discovery ==========
========== Test discovery skipped: All test containers are up to date ==========
Building Test Projects
Starting test discovery for requested test run
========== Starting test discovery ==========
NUnit Adapter 4.5.0.0: Test discovery starting
NUnit Adapter 4.5.0.0: Test discovery complete
========== Test discovery finished: 6 Tests found in 545,6 ms ==========
Executing all tests in project: SimpleNUnitTests
========== Starting test run ==========
NUnit Adapter 4.5.0.0: Test execution started
Running selected tests in C:\Users\XXX\source\repos\SimpleRhinoTests\SimpleUnitTests\bin\Debug\net7.0-windows\SimpleNUnitTests.dll
   NUnit3TestExecutor discovered 6 of 6 NUnit test cases using Current Discovery mode, Non-Explicit run
The active test run was aborted. Reason: Test host process crashed
========== Test run aborted: 0 Tests (0 Passed, 0 Failed, 0 Skipped) run in < 1 ms ==========

That solution is here: https://github.com/Sonderwoods/SimpleRhinoTests/tree/vanilla Any clue why it is crashing before running the tests?


After that, i cleaned up frameworks and added a clean Rhino plugin project using the McNeel VS templates. I enabled WPF and Windows.Forms in the template and hchanged targetframeworks to net7.0-windows

Now I'm getting a whole new error:

Building Test Projects
Starting test discovery for requested test run
========== Starting test discovery ==========
Microsoft.VisualStudio.TestPlatform.ObjectModel.TestPlatformException: Testhost process for source(s) 'C:\Users\XXX\source\repos\SimpleRhinoTests\SimpleUnitTests\bin\Debug\net7.0-windows\SimpleNUnitTests.dll' exited with error: Failed to create CoreCLR, HRESULT: 0x80070057
. Please check the diagnostic logs for more information.
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Client.ProxyOperationManager.ThrowOnTestHostExited(IEnumerable`1 sources, Boolean testHostExited) in /_/src/Microsoft.TestPlatform.CrossPlatEngine/Client/ProxyOperationManager.cs:line 520
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Client.ProxyOperationManager.SetupChannel(IEnumerable`1 sources, String runSettings) in /_/src/Microsoft.TestPlatform.CrossPlatEngine/Client/ProxyOperationManager.cs:line 294
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Client.ProxyDiscoveryManager.InitializeDiscovery(DiscoveryCriteria discoveryCriteria, ITestDiscoveryEventsHandler2 eventHandler, Boolean skipDefaultAdapters) in /_/src/Microsoft.TestPlatform.CrossPlatEngine/Client/ProxyDiscoveryManager.cs:line 149
========== Test discovery aborted: 0 Tests found in 75,4 ms ==========
========== Starting test run ==========
========== Test run aborted: 0 Tests (0 Passed, 0 Failed, 0 Skipped) run in < 1 ms ==========

This solution is on this branch: https://github.com/Sonderwoods/SimpleRhinoTests/tree/extraProject

Any clues?

if it's working on your end I guess it has to do with my local dotnet installations...

Thanks again

Sonderwoods avatar Jul 04 '24 13:07 Sonderwoods