Wednesday, 7 August 2013

Running unit tests in VS2012 from network shares / within VM

Running unit tests in VS2012 from network shares / within VM

Running Visual Studio 2012 with Update 3 and ReSharper 7.1.3 running in a
VMWare machine with Windows 7 64bit.
When working with projects on network shares or mapped drives I found that
the assemblies are not being loaded due to the change in CAS policies with
.NET 4.0
System.NotSupportedException: An attempt was made to load an assembly from
a network location which would have caused the assembly to be sandboxed in
previous versions of the .NET Framework. This release of the .NET
Framework does not enable CAS policy by default, so this load may be
dangerous. If this load is not intended to sandbox the assembly, please
enable the loadFromRemoteSources switch. See
http://go.microsoft.com/fwlink/?LinkId=155569 for more information.
I know I need to add the reference to loadFromRemoteSources = true to a
config file somewhere but so far the following have not worked
devenv.exe.config all of the resharper testrunner ones

No comments:

Post a Comment