Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

The directory containing the assemblies for the Visual Studio Test Runner is not valid

We have upgraded our TFS installation from 2012 to 2013. When running our builds they will fail with the following error if unit tests are enabled:

TF900547: The directory containing the assemblies for the Visual Studio Test Runner 
          is not valid ''

The build process template or build definitions has not been changed after the upgrade. The upgrade process did not change them. Where can I provide the path to the Visual Studio Test Runner and where is it located on disk?

I do not know if "Visual Studio Test Runner" is a new option for 2013 or if this setting was also used before, when we were using TFS 2012.

We use Visual Studio Professional 2012 on the build server.

like image 521
Magnus Lindhe Avatar asked Nov 23 '13 15:11

Magnus Lindhe


4 Answers

To do the second choice in Oswald's answer:

  1. Right click on your build definition and select "Edit Build Definition..."
  2. Click on the "Process" group in the build definition.
  3. Find the "Automated Tests" group under "Build Process Parameters" and click on the ellipsis.
  4. A "Automated Tests" dialog box will appear, select the test under "Tests to run" that you want to edit.
  5. Click on the "Edit", a "Add/Edit Test Run" dialog box will appear.
  6. Change the test runner to "MSTest.exe test runner"

Note: I am using TFS2012

like image 153
muneeb Avatar answered Nov 16 '22 03:11

muneeb


You have two choices:

  1. Install Visual Studio 2013 or the Agents for Microsoft Visual Studio 2013 if you want to continue to use the Visual Studio Test Runner.
  2. Switch to MS Test as the test runner and change the Tools Version in the Build-Workflow. This will allow you to continue using Visual Studio 2012 on the build server.

Note: Tank you SteveC to post the link to the agents only site

like image 40
Oswald Avatar answered Nov 16 '22 03:11

Oswald


The solution for us was to install the Agents for Microsoft Visual Studio 2013, rather than Visual Studio 2013

like image 36
SteveC Avatar answered Nov 16 '22 03:11

SteveC


As an alternative to installing Visual Studio on the build machine, you can simply copy the files from your local machine to the build machine.

ZIP the TestWindow folder found in

C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\CommonExtensions\Microsoft

then copy it to the build machine, and unzip to the same location.

like image 44
Dave Johnson Avatar answered Nov 16 '22 02:11

Dave Johnson