1

I have an issue running some moles tests within Visual Studio 2010. Within a test fixture, I have 4 tests - which when I run them in Debug mode, they all work properly.

When I run them using "Run Tests" rather than "Debug Tests", one in particular fails and the following error is given:

Problem signature:

Problem Event Name: CLR20r3

Problem Signature 01: microsoft.moles.vshost.x86.exe

Problem Signature 02: 0.94.0.0

Problem Signature 03: 4cc31915

Problem Signature 04: mscorlib

Problem Signature 05: 4.0.0.0

Problem Signature 06: 4d53693b

Problem Signature 07: 23d7

Problem Signature 08: 33

Problem Signature 09: System.AccessViolationException

OS Version: 6.1.7600.2.0.0.272.7

Locale ID: 1033

Additional Information 1: 0a9e

Additional Information 2: 0a9e372d3b4ad19135b953a78882e789

Additional Information 3: 0a9e

Additional Information 4: 0a9e372d3b4ad19135b953a78882e789

All of the tests involve load types and create instances dynamically, although the that fails does some additional inspection on the type by examining an attribute on the class, de-serializing xml into an instance of a type, then using that as an argument to the constructor of the type.

Not sure why that should cause any specific issues, but that's the only thing I've been able to isolate.

Any help would be greatly appreciated.

EDIT:

I initially provided the error thrown by the host, here's the error reported by the VS test runner:

The test adapter 'MolesAgentAdapter' threw an exception while running test 'Create_Returns_Configuration_When_Configured_Rule_Specifies_Configuration_Data'. Failed to read from an IPC Port: The pipe has been ended.

Community
  • 1
  • 1
dotnetnate
  • 769
  • 4
  • 11
  • Mh, I haven't seen this in conjunction with Moles. Although the error says 'moles' here and there, could it be that something else is causing the issue, e.g. code coverage, intelli trace, etc.? You might want to disable other testing features in `Test -> Edit Test Settings -> Data and Diagnostics`. Kind of a long shot, sorry. – mnemosyn Jun 03 '11 at 17:49
  • 1) Are you using the default test interfaces provided by Visual Studio? 2) Have you tried re-installing PEX/Moles? 3) If all else fails, try rebooting =) – Mike Christian Jun 20 '11 at 19:33
  • @mnemosyn - I'll give that a try; for now I just disabled the test which obviously isn't a solution @mike - 1.) yes, 2.) no , 3.) I've rebooted many, many times in the process ;) – dotnetnate Jun 20 '11 at 20:12

1 Answers1

0

I have had the same problem many times over, but was eventually able to solve it by disabling the 'Test Impact' feature in the data and diagnostics section of the solution test run config file (*.testrunconfig)

Just go to Test Settings > Data and Diagnostics > Test Impact and untick the little checkbox.

When it is on, I get the problem you describe, when it is off, everything works just fine. Maybe the PEX team will get this resolved in the next release (I hope)

A.R.
  • 15,405
  • 19
  • 77
  • 123
  • doesn't work for me( test impact was turned off all the time I have this problem – chester89 Dec 16 '11 at 08:46
  • rats. Now that you mention it, it doesn't work for me either (sometimes) so I am back to getting intermittent failures. I'll let you know if I come up with anything else in the meantime. Sorry for the bad advice. – A.R. Dec 16 '11 at 12:42