by Klaus Graefensteiner
1. July 2011 06:11
It is possible. Here is how
Development
Develop your NUnit tests with Visual Studio 2010 and the MSTest Coded UI Test facilities.
Automated Test
On the test or build machine you need to install the VisualStudio 2010 Test Agent and manually add the following assembly to the global assembly cache. Otherwise you will run into the following error when automating against Internet Explorer:
System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.VisualStudio.OLE.Interop,
Version=7.1.40304.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
The system cannot find the file specified.
The fix
The VisualStudio Test Agent installs the Microsoft.VisualStudio.OLE.Interop dll, but doesn’t add it to the GAC (Global Assembly Cache). Visual Studio on the other side does.

Use the GACUtil.exe utility, which can be found on the Visual Studio machine or the Windows SDK. Run this utility with the /i switch and make it point to the assembly.
gacutil /i C:\Program Files (x86)\Common Files\microsoft shared\VSTT\10.0\Microsoft.VisualStudio.OLE.Interop.dll
Ausblick
That’s it. Happy testing!