Test execution fails if solution contains native C++ project
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
NUnit Test Adapter |
Fix Released
|
High
|
Charlie Poole |
Bug Description
My solution contains a native C++ project. If I try to run a unit test from the C# test project, I get the following output:
========== Discover test finished: 0 found (0:00:04,2581721) ==========
------ Discover test started ------
Assembly not supported: D:\GXR\
An exception occurred while test discoverer 'NUnitTestDisco
========== Discover test finished: 0 found (0:00:00,779885) ==========
Please note that I try to start a unit test from a totally different (C#) project.
If I open the Test Explorer and rebuild the solution, I get the same error output.
Changed in nunit-vs-adapter: | |
assignee: | nobody → Charlie Poole (charlie.poole) |
milestone: | none → 0.94 |
Changed in nunit-vs-adapter: | |
status: | Fix Committed → Fix Released |
This is a bit of a mystery. The first message "Assembly not supported..." is from the adapter. After it sends the message, it abandons any processing on the invalid assembly and goes on to the next one.
The second message is from the test discovery engine. A known problem with this message is that the null reference appears to occur when the engine is processing a _different_ exception, making debugging a bit hard. Note that we can't tell from the output if that exception is caused by the C++ assembly or by some other assembly processed after it. There are two ways to find out:
1) Drop any other projects from your solution temporarily. No tests will be found, of course, but we'll see whether the second message continues to appear.
2) I can send you a debug build, which will include a few more lines of output as each assembly is processed.
Charlie