Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to specify the location for the unit test results in VS 2010?

I use VS2010 for unit testing. Does anyone know how to specify the location of where VS 2010 put its TestResults? By default it put a TestResults folder in the solution folder, I'd like to move it out somewhere else.

Thanks, Ray.

like image 956
Ray Avatar asked May 25 '10 20:05

Ray


1 Answers

Currently, this is not possible to control from within the IDE, see http://social.msdn.microsoft.com/Forums/en/vststest/thread/4ff650e1-a99a-4bd4-8311-6007f2a6e16e.

However, if you can use MSTEST.EXE from the commandline, it will use the current folder to generate the TestResults folder in.

Update:

Found this in http://blogs.msdn.com/b/vstsqualitytools/archive/2010/10/24/test-agent-test-controller-and-mstest-faq.aspx:

How to customize the default deployment directory?

You can change the default deployment folder by editing the test settings file in the XML editor:

<Deployment userDeploymentRoot="C:\TestResults" useDefaultDeploymentRoot ="false" /> 

Note that ,if the test settings is modified by XML edit (instead of using the default editor) VS need to be closed and reopened ( since the editing is done in XML , the changes will not be updated in the loaded settings.)

Best regards, Marco Kroonwijk

like image 170
kroonwijk Avatar answered Sep 20 '22 14:09

kroonwijk