chugh97
chugh97

Reputation: 9974

VS2008 Unit tests failed when you select Test- Debug- All Tests in Solution

in Debug mode the tests which throw a custom exception give an error message like

Exception of type 'CustomProductException' was thrown instead of 'CustomProductException'

Fail.But when I choose Test - Run - All Tests in Solution rather than Debug, all Tests pass.Why is this happening? Any pointers...

Upvotes: 0

Views: 156

Answers (1)

user1228
user1228

Reputation:

I've had this happen before. I believe the issue was my references. Clean your entire solution, and delete every reference in every project in your solution to the assembly that contains CustomProductException.

Next, re-add your references, making sure to reference the project that compiles the assembly, not the compiled assembly on disk.

Upvotes: 1

Related Questions