Skip to Main Content

ODP.NET

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

11.2 ODP.NET causing test runner failures

786844Aug 9 2010 — edited Aug 10 2010
Hello,

I've been banging my head against the wall with this one, and I am hoping someone can suggests how I might go about solving my particular problem. For reference sake, here is my development platform:

- Windows 7 x64 (4GB RAM, plenty of hardware...), VS2010, .NET 4.0, xunit testing framework and testdriven.net

We are in the process of upgrading our ODAC (Oracle.DataAccess.dll) components for our .NET applications from 2.102.4.0 to 2.112.1.0.

In doing so, I have installed the 11.2g Oracle client, and pointed our integration test assemblies to the new DLL. Almost all of our integration tests are executed by middle-tier components, which in turn call a data access assembly. The data access assembly has a reference to the Oracle.DataAccess.dll. All these test execute and pass as expected using both versions of the Oracle.DataAccess.dll.

There are however a few tests that invoke the data access assemblies directly. This is where we are having problems. Strangley enough, the test framework we use (xunit) passes all the tests. But after the test run has been completed, the test runner (testdriven.net) throws an exception -

Test 'T:Oracle11gTestProject.ElevenGTests' failed: Error while unloading appdomain. (Exception from HRESULT: 0x80131015)*
+ System.CannotUnloadAppDomainException: Error while unloading appdomain. (Exception from HRESULT: 0x80131015)+

It appears that the process that loads the tests is unable to dispose of a reference it has. Thinking it may be the test framework, and test runner, I created a new MS Test project using the test framework that is built into VS2010. Again, the test pass, but the test runner throws a similar error:

+(QTAgent.exe, PID 4592, Thread 8) ResolutionAppDomainHelper.Unload: An error occurred while attempting to unload the tests AppDomain. The AppDomain may still have foreground threads executing.+

This is exactly the same error as TestDriven.Net. The only thing I can associate this behaviour with is the Oracle 11.2 Client. If I remove the 11.2 client from my machine, all tests and all frameworks pass (and behave) as expected. With 11.2 client, they do not.

We are in a difficult position now, because we cannot make the transition as long as there are tests that fail.

Has anyone else experienced this problem? Any suggestions would be much appreciated.

Regards,

Steve
This post has been answered by JennyJ-Oracle on Aug 9 2010
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 7 2010
Added on Aug 9 2010
2 comments
2,075 views