locked
Silverlight/Virtual Machine/Build Question RRS feed

  • Question

  • I have created a number of Coded UI tests against a Silverlight 4 application with the Microsoft.VisualStudio.TestTools.UITest.Extension.SilverlightUIAutomationHelper.dll added appropriately to Silverlight project I am testing against.  I am not creating builds under the Silverlight project.  I have my own solution/project/source control where I house my tests, build and deploy through TFS.

    These tests work and run beautifully on my local machine through VS2010 or through MTM, but fail when I attempt to run on a virtual machine through MTM Lab Manager.  I receive a "Unit Test Adapter threw exception:
    Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.." error.  When I drill deeper into the error, I get "Exception: Thrown: "Could not load file or assembly 'Microsoft.Visualstudio.QualityTools.Common' or one of its dependences.  The system cannot find the file specified." (System.IO.FileNotFoundExpception)"

    I know it has nothing to do with the VM as I have a non-Silverlight project and can run those Coded UI tests on my VMs with no issues.

    I am beating my head on the desk trying to figure out why.  Most information I've found lead me to believe it is code analysis problem, however I do not have code analysis turned on anywhere. Other information seems to state some problems with Silverlight.  I have tried changing the "Copy Local" settings to make sure the references are packaged with the test dlls.  I have tried creating debug versus release builds.  I have tried removing and reloading the references.  I've tried changing to X86 for the MSBuild Platform in my build template.  I have tried many other things, too.

    Since I am creating my own builds outside of the Silverlight project I am testing against, I have added Microsoft.VisualStudio.TestTools.UITest.Extension.SilverlightUIAutomationHelper.dll to my project, but that does not help.

    My head hurts from beating it on my desk.  Does anyone have any other ideas I can try or please tell me what I am doing wrong.

    Thank you!

     

     

    Tuesday, July 26, 2011 3:11 PM

All replies

  • In order to resolve this issue, the system must have Visual Studio Feature Pack 2 installed (http://msdn.microsoft.com/en-us/library/gg269474.aspx)  This provides all of the Silverlight testing tools.

    Thursday, September 1, 2011 10:51 PM
  • Try doing this - Edit the Deployment section in your remote test settings and try explicitly giving the list of dlls in the additional files to deploy. 

    Wednesday, September 7, 2011 7:18 PM
  • Unfortunately, I have Visual Studio Feature Pack 2 installed.  Any other thoughts?
    Monday, September 19, 2011 10:09 PM
  • Orange 25, 

    I have mucked with that some with no success.  Are you referring to specific dlls?

    Monday, September 19, 2011 10:11 PM