Tag Archives: TFS

System Center Virtual Machine Manager + TFS for automatic testing

Spent the last two days setting up a solution at a customer together with Mattias Olausson from Callista. Our customer wants automatic testing of the nightly builds of their software, a task managed manually until now.

The setup consists of two servers, one running TFS (Team Foundation Server) and another one running System Center Virtual Machine Manager 2008 R2. Besides this we have a Hyper-V host for running the workloads. In SCVMM we’ve created four templates for the client operating systems that the tests should be run on, Windows 7 x86/x64 and Windows XP x86/x64. On these virtual machines we’ve installed all the necessary agents needed by TFS, converted them to templates in SCVMM and added sysprep.inf / unattend.xml to each template to enable a zero touch installation of each operating system.

In TFS Lab Manager you then create a testing project with a virtual infrastructure connected to it, and you select the templates you wish to run. TFS will then deploy the VM’s and run the tests you’ve configured. A report from the test will be written to your selected output directory and the VM’s will be destroyed.

If you’re interested in setting it up, the TFS team have a really good series of articles explaining everything in detail: http://blogs.msdn.com/b/lab_management/archive/2010/03/29/setting-up-various-topologies-to-test-with-visual-studio-team-lab.aspx

There’s also a basic concept overview at http://blogs.msdn.com/b/lab_management/archive/2009/05/18/vsts-2010-lab-management-basic-concepts.aspx

As far as SCVMM and Hyper-V goes you’ll find the basic configuration steps over at http://blogs.technet.com/b/scvmm/archive/2009/01/05/scvmm-2008-installation-step-by-step.aspx

And once you’ve got that up and running, you can run all your tests in the middle of the night and be a lot more productive during the days (sounded like straight from marketing, didn’t it…)!