How do I run many unit tests in Build-Deploy-Test build in TFS 2010?

258 Views Asked by At

I have been using the Build-Deploy-Test build workflow for TFS 2010 (see here http://msdn.microsoft.com/en-us/vstudio/gg131922.aspx) and have come up against a very annoying limitation.

Here is what I have done:

  • Setup a build to be queued
  • Configured it to restore to a test-ready snapshot
  • Added some deployment steps; in this case starting mongo db

I then came to the step where you configure which tests to run and hit an issue. Firstly you need configure a test plan with some test suites; a test suite consisting of test cases. The problem is that each test case can only be associated with a single unit test.

With having to create a test case per unit test, it means that every time a unit test is added a new test case must be created. Is there any way you can associate many unit tests with a test suite that can be ran in the Build-Deploy-Test build workflow.

2

There are 2 best solutions below

2
On BEST ANSWER

One way around this problem is to update your test suite using the tcm.exe testcase /import /syncsuite: command. This command has to be run before test execution begins and a logical place to add it would be into the build template.

0
On

I suggest you to use Test List Editor in Test Tab on Visual Studio, create your differents lists of tests, organize your tests based on functionnal after that you can execute on your build list of tests by entering name of list.

link : http://msdn.microsoft.com/en-us/library/ms182463(v=vs.100).aspx

For configuring Build Definition, i suggets you to edit & select Automated Test Tab and insert list.

link : http://support.smartbear.com/articles/testcomplete/testcomplete-and-team-build/