What steps will reproduce the problem?
1. Create test project;
2. Add a helper static class (detailed below);
3. Try to run tests
What is the expected output? What do you see instead?
Expected:
projects should build and the tests should run
Actual:
the test assembly is not loaded (output window message: Error loading <testassembly.dll>: An exception occurred while invoking a test driver.) and no tests are found in the solution.
What version of the product are you using? On what operating system?
3.2 RTM, Win7 x64
Please provide any additional information below.
The following type of class causes the described behavior:
public static class MockObjectSetExtension
{
public static IObjectSet<T> AsObjectSet<T>(this List<T> entities) where T : class
{
return new MockObjectSet<T>(entities);
}
}
where IObjectSet is defined in System.Data.Entity and MockObjectSet is a very
simple implementation of it. Deleting this class fixes the issue and makes the
tests run. Also, adding it after at least one successful test run does not
cause more problems until the solution is reopened (took me a while to realize
that).
The Event Viewer entry states pretty much the same thing as the output window
message:
(devenv.exe, PID 1932, Thread 1) SolutionIntegrationManager:
SolutionIntegrationManager::LoadFileIntoTmi: Failed to load <testassembly.dll>
for some systemic reason: An exception occurred while invoking a test driver.
There are other events containing exception traces but they don't seem to be
related to this one - i.e. they aren't occurring every time this one occurs.
Let me know and I'll try to post more details if needed.
Original issue reported on code.google.com by alexpa...@gmail.com on 27 Sep 2010 at 4:10
Original issue reported on code.google.com by
alexpa...@gmail.com
on 27 Sep 2010 at 4:10