The MSTestActivity was invoked without a value for either TestMetadata or TestContainers.Hi,<br/> <br/>  I've created a simple solution that I've checked into TFS (2010 beta1) and I've created a build type for continuous integration.<br/> <br/>  Run Tests i set to true and I've assigned a testsettings file as well as a vsmdi file. When the build server build the projects, it<br/>  runs the tests (it's actually right now only a single unit test / method) but it spits out the following error message after it finish<br/>  the test run:<br/> <br/>  The MSTestActivity was invoked without a value for either TestMetadata or TestContainers.<br/> <br/>  How do I fix this?<br/> <br/>  --larsw<hr class="sig">Lars Wilhelmsen | Senior Consultant | <a href="http://www.miles.no/">Miles</a>, Norway | <a href="https://mvp.support.microsoft.com/profile/Lars">Connected Systems MVP</a> | <a href="http://larswilhelmsen.com/">http://larswilhelmsen.com/</a>© 2009 Microsoft Corporation. All rights reserved.Mon, 28 Sep 2009 15:50:06 Z7011dc2a-d722-47e9-92b7-4d899e799bfehttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#7011dc2a-d722-47e9-92b7-4d899e799bfehttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#7011dc2a-d722-47e9-92b7-4d899e799bfeLars Wilhelmsenhttp://social.msdn.microsoft.com/Profile/en-US/?user=Lars%20WilhelmsenThe MSTestActivity was invoked without a value for either TestMetadata or TestContainers.Hi,<br/> <br/>  I've created a simple solution that I've checked into TFS (2010 beta1) and I've created a build type for continuous integration.<br/> <br/>  Run Tests i set to true and I've assigned a testsettings file as well as a vsmdi file. When the build server build the projects, it<br/>  runs the tests (it's actually right now only a single unit test / method) but it spits out the following error message after it finish<br/>  the test run:<br/> <br/>  The MSTestActivity was invoked without a value for either TestMetadata or TestContainers.<br/> <br/>  How do I fix this?<br/> <br/>  --larsw<hr class="sig">Lars Wilhelmsen | Senior Consultant | <a href="http://www.miles.no/">Miles</a>, Norway | <a href="https://mvp.support.microsoft.com/profile/Lars">Connected Systems MVP</a> | <a href="http://larswilhelmsen.com/">http://larswilhelmsen.com/</a>Fri, 22 May 2009 08:18:00 Z2009-05-22T08:18:00Zhttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#190629f5-5539-4da7-acbb-f8ec2dc93a2bhttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#190629f5-5539-4da7-acbb-f8ec2dc93a2bAnutthara - MSFThttp://social.msdn.microsoft.com/Profile/en-US/?user=Anutthara%20-%20MSFTThe MSTestActivity was invoked without a value for either TestMetadata or TestContainers.<p><span style="color:#000080">Hey Lars - in the build definition &quot;Process&quot; tab there is an option to choose the test list to run. Have you chosen the right .vsmdi file and the test list to run as part of the build there? </span></p> <p><span style="color:#000080">If not, point to your .vsmdi file and choose &quot;run all tests&quot; - that should give you test results on the build. HTH!</span></p> <p><span style="color:#000080">- Anu </span>  </p><hr class="sig">http://blogs.msdn.com/anuttharaFri, 22 May 2009 11:24:43 Z2009-05-22T11:24:43Zhttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#f85407a0-ca4b-45dd-83c2-12565e027ea4http://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#f85407a0-ca4b-45dd-83c2-12565e027ea4Lars Wilhelmsenhttp://social.msdn.microsoft.com/Profile/en-US/?user=Lars%20WilhelmsenThe MSTestActivity was invoked without a value for either TestMetadata or TestContainers.Hi Anutthara,<br/><br/> Are you referring to the &quot;Test Metadata Files&quot; option in the property grid? If so, yes - I've assigned the default .vsmdi file that was generated<br/> when I added the Test project to the solution, and I selected the &quot;Run all Tests&quot; node.<br/><br/> --larsw<hr class="sig">Lars Wilhelmsen | Senior Consultant | <a href="http://www.miles.no/">Miles</a>, Norway | <a href="https://mvp.support.microsoft.com/profile/Lars">Connected Systems MVP</a> | <a href="http://larswilhelmsen.com/">http://larswilhelmsen.com/</a>Fri, 22 May 2009 11:56:19 Z2009-05-22T11:56:19Zhttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#d687f0ea-33aa-4194-aef3-c3830e292b2chttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#d687f0ea-33aa-4194-aef3-c3830e292b2cKarl Zhttp://social.msdn.microsoft.com/Profile/en-US/?user=Karl%20ZThe MSTestActivity was invoked without a value for either TestMetadata or TestContainers.I finally got past this. I created a Test List called &quot;Build&quot;. I then added ALL my tests to that test list and specified the Build test list rather than &quot;Run all tests in this VSMDI file&quot;.<br/><br/>At least a work around for me for Beta 1...Mon, 25 May 2009 15:34:20 Z2009-05-25T15:34:20Zhttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#941b3767-2875-4cbb-9438-6ed7e1a7b4f7http://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#941b3767-2875-4cbb-9438-6ed7e1a7b4f7Lars Wilhelmsenhttp://social.msdn.microsoft.com/Profile/en-US/?user=Lars%20WilhelmsenThe MSTestActivity was invoked without a value for either TestMetadata or TestContainers.Hi Karl,<br/><br/> Same thing worked for me - I just forgot to reply to this thread.<br/><br/> --larsw<hr class="sig">Lars Wilhelmsen | Senior Consultant | <a href="http://www.miles.no/">Miles</a>, Norway | <a href="https://mvp.support.microsoft.com/profile/Lars">Connected Systems MVP</a> | <a href="http://larswilhelmsen.com/">http://larswilhelmsen.com/</a>Mon, 25 May 2009 17:56:23 Z2009-05-25T17:56:23Zhttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#663de315-6110-4cda-ac85-728b5e639cb1http://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#663de315-6110-4cda-ac85-728b5e639cb1Michael Heitlandhttp://social.msdn.microsoft.com/Profile/en-US/?user=Michael%20HeitlandThe MSTestActivity was invoked without a value for either TestMetadata or TestContainers.Hi, I tried the same but it did not work for me. I got the following error message: &quot;'MSTest.exe' returned an unexpected exit code. Expected '0'; actual '1'.&quot; Extract from my Log file see below. Any Ideas? Cheers, Michael APPENDIX Run Tests 00:17 If Not TestProjects Is Nothing 00:17 For Each TestProject in TestProjects 00:16 Try Run Tests for TestProject 00:16 Run MSTest for Project 00:00 Convert Server Path to Local Path 00:16 Run MSTest for Project C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\MSTest.exe /nologo /searchpathroot:&quot;C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp\1\ContinuousIntegrationDemo\BuildDefinition1\Binaries&quot; /resultsfileroot:&quot;C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp\1\ContinuousIntegrationDemo\BuildDefinition1\TestResults&quot; /testmetadata:&quot;C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp\1\ContinuousIntegrationDemo\BuildDefinition1\Sources\ContinuousIntegrationDemo1.vsmdi&quot; /testlist:&quot;MyTestList&quot; /publish:&quot;http://caa1747-2008v:8080/tfs/DefaultCollection&quot; /publishbuild:&quot;vstfs:///Build/Build/48&quot; /teamproject:&quot;ContinuousIntegrationDemo&quot; /flavor:&quot;Debug&quot; No platform specified for publish operation. For switch syntax, type &quot;MSTest /help&quot; 00:00 Handle MSTest Exception 'MSTest.exe' returned an unexpected exit code. Expected '0'; actual '1'. 00:00 Set TestStatus to Failed Wed, 29 Jul 2009 21:47:25 Z2009-07-29T21:47:25Zhttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#7660e7ed-6a3e-4c4d-a020-7f75a32adcafhttp://social.msdn.microsoft.com/Forums/en-US/tfsprerelease/thread/7011dc2a-d722-47e9-92b7-4d899e799bfe#7660e7ed-6a3e-4c4d-a020-7f75a32adcafCezary Nolewajkahttp://social.msdn.microsoft.com/Profile/en-US/?user=Cezary%20NolewajkaThe MSTestActivity was invoked without a value for either TestMetadata or TestContainers.Hi, <br/><br/>The platform needs to be specified in the Build Definition, Process tab, Comilation section. <br/><br/>the Configuration to Build needs to indicate both, configuration AND platform: Debug|Any CPU.<br/><br/>Then, the Platform parameter for the MSTest.exe is passed from that configuration data.<br/><br/>I hope this would help if someone is still looking for the answer.<br/><br/>Best regards,<br/>Cezary Nolewajka<br/>Mon, 28 Sep 2009 15:50:06 Z2009-09-28T15:50:06Z