Hi there,
I've been trying to use the nunit2 task to unit test some MVC controllers
and have been seeing the following exception:

  [nunit2] 21)
Otu.Web.UnitTests.Controllers.RegistrationControllerUnitTests.Execute_should_return_registration_complete_view_when_registration_is_in_session
: SetUp : System.InvalidOperationException : Dynamic operations can only be
performed in homogenous AppDomain.

Investigating a little further, it seems that the task should be creating
Homogenous AppDomains when running test assemblies that may be using DLR
features.

Looking at the source, it seems  that someone did think of this, but the
code is #if'd out, and that code does not appear in the download binaries :

#if NET_4_0
            PermissionSet myDomainPermSet = new
PermissionSet(PermissionState.Unrestricted);
            return AppDomain.CreateDomain(domSetup.ApplicationName,
AppDomain.CurrentDomain.Evidence, domSetup, myDomainPermSet);
#else


I realize that 4.0 specific code may not be to everyone's taste, but
perhaps there could be a side-by-side release of a .Net 4.0 binary build?
 (I'd really prefer to be using "blessed" releases rather than baking my
own)


Pete

-- 
<http://www.fsf.org/fb>
http://www.fsf.org/facebook
http://bit.ly/hzA1MS
http://bit.ly/fztcGn
http://cli.gs/V1UtWw
http://cli.gs/S3zVIt
http://goo.gl/ZBptR
http://goo.gl/tXFO7 <http://goo.gl/ZBptR>
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
NAnt-users mailing list
NAnt-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-users

Reply via email to