One of the common issues regularly faced by our users is how to test their application in both IE and Firefox. Visual Studio Lab Management can help in solving this issue for automated Coded UI test as part of Lab E2E Workflow flow.
To accomplish this with Lab Management, we will need
Lab Management uses Test Settings to define the Role of the environment to use for running test and also for data collection. If there are more than one machines of the Execution role in the environment, then the tests are distributed among them. For configuration matrix testing between IE and Firefox we want to be sure that all our tests run both on IE and Firefox.
So to accomplish our goal we will be using multiple test settings and multiple automated test runs within our environment.
Let us setup the environment now, to do that we do the following:
With these steps our environment is ready. Now we will do the setup of the test cases.
Now we need to setup the build:
Now we can run this build and it will go through the build, deploy & test phases. It will create and execute two test runs by the name BuildNumber & BuilNumber_2, we can check them under Test > Analyze Test Runs page of Microsoft Test Manager.
With this we have accomplished our goal of executing same set of tests on both IE and Firefox using Lab E2E workflow.
For running the test in Firefox, we used a feature introduced in Feature Pack 2 (more info) to capture Coded UI test in IE and run them in Firefox. If you want to run the configuration matrix across various versions of IE, we do not need to install Feature Pack 2, we just need to have the different versions of IE installed on the two WebClient machines we have in our environment.
You can also extend this testing to beyond two runs by modifying the build template to include more test runs and creating the additional web client machines and test settings in the environment.