开发者

VS10 debugger error: Test host process exited unexpectedly

I have been having some problems with the test debugger in VS10. All tests are running without error, but when debugging it aborts when I try to read the object data. Afterwards, this error is displayed in the summary: Test host process exited unexpectedly.

I'm unable to see anymore details about the error. How do I access/generate test-log files? Or, even better: Has anyone experienced a similar problem? And found a solution?


Additional information:

The runtime-test-data is available on objects from same libary assembly, it's just one class I can't get access to in runtime mode. If I use breakpoints at:

  • every line that affects the object: - I can see the runtime-data and the test passes
  • only one place: - the test will abort and no data is visible
  • no breakpoints: - the test runs and passes.

The test used to work fine until recently. Just before the problem occurred when I made some solution changes with dividing the projects into solution folders. I didn't make any changes that should affect the code. Moving the projects back to their original folder don't solve the problem, So I wonder - Is this a bug in Visual Studio itself?

Here is what I've tried so far:

  • Rebuilding and cleaning the solution.
  • Closing Visual Studio and rebooting my system.
  • Installing VS10 Service Pack 1
  • Reinstalling Visual Studio 10
  • Testing on VS10 Ultimate and Premium
  • Removing and regenerating solutions files
  • Removing all break points
  • TraceAndTestImpact/Local.testsettings: Testing Timeout > timeout and setting abort to 30 minutes.
  • TraceAndTestImpact/Local.testsettings: Unit Test > Assembly folders defined
  • TraceAndTestImpact/Local.testsettings: Deployment > Enable deployment directories and files
开发者_如何学Go

How can I fix this? Any suggestions are welcome.


What's most likely happening here is that a property, local which is being evaluated in the locals or autos window is causing a side effect in the running process which leads to the failure. To verify this you should turn off automatic property evaluation

  • Tools -> Options
  • Go to the Debugger menu
  • Uncheck "Enable Property evaluation and other implicit function calls"


Solution: It had overridden ToString, and as it showed out, there was a loop i forgot to close. After altering ToSting everything works fine.

Thank you very much for the answers :)


I was getting a similar issue, however in my case ALL tests were being skipped, and the error was reproducible on an empty test project, so code was ruled out.

Checking the EventViewer led me to the cause in my case; somehow the C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\QTAgent32.exe.config file had been removed from my machine?!? I copied one from another machine here and I'm back in action.


I was finally able to resolve this issue in my case. What was happening for me was I was running asynchronous threads, but closed a process using a synchronous Close() method for a powershell runspace rather than the asynchronous CloseAsync() method.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜