Showing posts with label TFS 2010. Show all posts
Showing posts with label TFS 2010. Show all posts

Sunday, 12 May 2013

Installing and Configuring a Test Controller and a Test Agent for VS2010 and TFS 2010


To run tests remotely on one or more computers using Microsoft Visual Studio 2010, you have to install a test controller, and test agents. You install a test controller on any suitable computer, and a test agent on each of the computers that are running components of the system under test. The test controller communicates with the test agents to initiate the tests and to collect test result data.

Before you install test controller and test agents, you should verify that you have the required hardware and software to meet your specific needs. For detailed information on test controller and test agent hardware and software requirements, see Test Controller and Test Agent Requirements.

There are two principal scenarios in which you install test controllers and agents:

Remote tests: You want to run tests by using Visual Studio 2010, and you want to run the system on one or more computers that are separate from your Visual Studio computer.
In this case you have to:


  • Install a test controller on a suitable machine.
  • Install a test agent on each machine on which the system under test will run.
  • Register each test agent with the test controller.




Lab tests: You want to run tests either manually or automatically on a lab environment by using Microsoft Test Manager and Visual Studio Lab Management. In this case you have to:



  • Install a test controller on a suitable machine.
  • Register the test controller with a Team Foundation project.
  • Install a test agent on each computer or virtual machine template on which tests will be run.

You can start by grabbing the ISO from http://www.microsoft.com/en-us/download/details.aspx?id=1334

Installing and Configuring a Test Controller

A single test controller manages one or more test agents by sending information to test agents about the task that the agent has to perform.

To install it, mount the ISO you downloaded and you should be able to run the setup.exe like so:

Select the "Install Microsoft Visual Studio Test Controller 2010".


Accept the terms & conditions.


Select the drive & click Install.




Once the installation has finished, click configure.


If you're installing this controller as a part of Lab Management, choose the "tfsadmin" account that you used while configuring TFS2010 for Lab Management. (Have a look at the "Prerequisites" http://msdn.microsoft.com/en-us/library/dd380687.aspx).

Register with the Team Project Collection you require.


You now need to "Apply Settings".



Installing and Configuring a Test Agent


A test agent can be installed in the following ways:
  • As a service
  • As an interactive process

If you want to run tests that interact with your desktop, such as coded UI tests, you must install the test agent that runs these tests as an interactive process. When you configure the test agent as part of the installation process, you can select how you want to run the agent. For more information about how to run a test agent as a process, see How to: Set Up Your Test Agent to Run Tests that Interact with the Desktop.

To install it, mount the ISO you downloaded and you should be able to run the setup.exe like so:

Click "Install Microsoft Visual Studio Test Agent 2010" and then you'll need to accept terms and conditions.



Choose the drive you'd like to install it to.




You must now also configure your agent. If you intend to run Automated UI Tests you should run it as an interactive process.


If you're installing this controller as a part of Lab Management, choose the "tfsadmin" account that you used while configuring TFS2010 for Lab Management. (Have a look at the "Prerequisites" http://msdn.microsoft.com/en-us/library/dd380687.aspx).

This account also needs to be a local admin on the machine.


If you'd like the test controller to be responsible for agents running on virtual environments using Lab Management, leave the "Register with Test Controller" unchecked.

Else, you should point to test controller we just created. If its on the same machine, it will be localhost:6901.

All you need to do now is Apply Settings.










Wednesday, 19 December 2012

Build Status Notification Lamp - TFS2010


Web Mail Notifier Sillyness


We have a dedicated build wall which is pretty efficient in displaying the build information. It really is!

BUT, ever since I moved my desk away from the big screen TV's that display the build notifications, it makes it difficult to tell what's the status of the builds at our morning stand-up.

This was until a couple of days ago a friend got me hooked on to the "USB Web Mail Notifier" available here. (Although, I bought mine off some random dude on EBay (from the UK).

All I really needed was to know if our Nightly Builds that run our Unit and Integrations Tests failed.

Now I know that there are heaps of other ways to get this information but the one I went with appealed to my inner nerd :)

By using a simple powershell script I am able to query our Team Foundation Server (TFS-2010) to see if the latest Nightly Build has been successful.

The powershell script and the binaries required to use the USB light are available here at http://tiny.cc/BuildNotification.

You need to customise the powershell script by entering your details in the  "Set user variables" section of the script:



This is what it looks like.

When developers have been naughty (and not run integration tests locally before checking in) ...



But after you fix it, all is good ..