Click here to Skip to main content
15,886,724 members
Articles
(untagged)

Coded UI Tests: Executing a Test Case While Desktop is Not Active

Rate me:
Please Sign up or sign in to vote.
5.00/5 (3 votes)
10 Dec 2012CPOL2 min read 19.4K   5   4
Coded UI Tests: Executing a test case while desktop is not active

One of the biggest time consuming and productivity killer task for automation engineers is the time when they are executing their scripts. Not only scripts take a long time to run but also while they are running, we cannot do anything else. This is a desire of every automation engineer that he could do some other work (like developing other test cases) while the previous test case executes.

Same case happens with me and I found a solution for that. Since coded UI tests require an active desktop screen to execute it, there are three ways to achieve this.

  1. Either you install Visual Studio on your development machine and install Test Agent on any other machine where you want to execute tests. When you will execute a test case on your development machine, it will be executed on the test machine PC and the development machine will remain free for doing other tasks.  (This approach requires another PC. That means it is an expensive approach)
  2. You can set up a VM machine of Windows 7 (or any other) on your development machine. On the VM machine, install Test Agent. When you will execute a test case on your development machine, it will be executed on the VM machine and development machine will remain free for doing other tasks. (This approach is less expensive.)
  3. You can set up a VM machine of Windows 7 (or any other) on your development machine. On the VM machine, install Visual Studio 2010 and get the latest version of your source code there with the help of TFS. In this approach, you will have two benefits:
    1. You will be able to execute test cases right from VM machine.
    2. You will be able to develop or modify test cases in the VM machine.

In approach number 3, you can run the test cases from Visual Studio inside VM machine and minimize that window. The code will be executed while this VM window is minimized. You will be free to do other tasks as well. I personally follow approach number 3. It allows me to change my code in both environments and by using TFS, I am also able to check in / check out my code at both locations and the code remains always updated.

What approach do you follow? and what are the benefits. I would love to hear it out.

Cheers!

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Tester / Quality Assurance
Pakistan Pakistan
Working as a Testing Automation Engineer.

Comments and Discussions

 
SuggestionUse SysInternals Desktops application Pin
John Brett11-Dec-12 5:07
John Brett11-Dec-12 5:07 
GeneralRe: Use SysInternals Desktops application Pin
joinsaad11-Dec-12 21:52
joinsaad11-Dec-12 21:52 
GeneralRe: Use SysInternals Desktops application Pin
John Brett11-Dec-12 22:13
John Brett11-Dec-12 22:13 
GeneralRe: Use SysInternals Desktops application Pin
joinsaad11-Dec-12 23:22
joinsaad11-Dec-12 23:22 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.