IOException Debugging Unit test

Hi,
When I try and debug one of my unit tests I get the following error "The process cannot access the file 'C:\Program Files\JetBrains\ReSharper\v3.0\vs8.0\Bin\DevExpress.Data.v7.1.dll' because it is being used by another process."
I've tried rebooting but that didn't help.

Any ideas?
Regards
Ian

4 comments
Comment actions Permalink

I found the problem by reverting to a Visual Studio Unit Test which allowed me to debug. There was an issue with my code. Not sure why the resharper test gave me this error though.

Thanks
Ian

0
Comment actions Permalink

I am also getting this issue. I have a unit test which tests xml serialization/deserialization. If I change the type that I am trying to serialize, I get this exception when debugging the unit test. I don't get it when running the unit test without debugging. Changing back to the original type does not get rid of the problem...weird. I found that deleting all temp files, including resharper files, gets rid of the problem. Is anyone else familiar with this problem?

0
Comment actions Permalink

I also found an error with my code. The new type that I was trying to serialize did not have a parameterless constructor. After deleting the temp files (as mentioned above) NUnit would then correctly report the InvalidOperationException. Maybe this has something to do with how resharper/NUnit behaved, but the fact that I had to delete all temp files to get it back to a working state indicates something funky going on somewhere. Thanks.

0
Comment actions Permalink

Hi.

I was getting this exception also. It seems that it appears when there is some kind of serialization problem (maybe other problem). Actually, it is internal exception of executed code and happens only when you have set “break on CLR exception” to on. If you turn this option off and surround code with try..catch you will get real correct exception. This is why some guys get correct exc when they are just running, but not debugging test method.

regards
i5riza

0

Please sign in to leave a comment.