Click here to Skip to main content
15,887,027 members
Articles / DevOps
Tip/Trick

Setup for Test Servers to Run Coded UI Tests from VSO/TFS 2015

Rate me:
Please Sign up or sign in to vote.
4.33/5 (2 votes)
11 Aug 2016CPOL2 min read 10.2K   1  
Setup required for Test Servers to run Coded UI Tests

Introduction

In order to run Coded UI Tests on Visual Studio Online or TFS 2015 On Premise, the test run servers need to be setup with several things which are not intuitive or setup automatically. There may be some extra steps needed depending on your system but this is the minimum I have had to do to get my servers up and running.

There are lots of tutorials and guides for setting up builds or releases to run tests, but I have never seen anything on the specific setups for the servers themselves to get them ready to and be ready to run tests.

I am not going to go into specific detail on some items, but this should at least get people around some of the issues and give some pointers in the right direction.

The Setup

  • Download and Install the 2015 Test Agent. Download from here.
  • Setup Windows Remote Management - Open a command prompt as admin and run the command "winrm quickconfig". If you do not do this, you will get ambiguous errors about not connecting to the server.
  • Disable lock screen
    • Run > gpedit.msc > Administrative Templates/Control Panel/Personalization/Do not display the lock screen > enabled
  • Enable auto login- Run > Regedit > HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/Windows NT/CurrentVersion/Winlogon >
    • Edit AutoAdminLogin to data = 1
    • Edit DefaultDomain to your domain (if you are on a domain)
    • Edit DefaultUserName to be the user to login that will run tests
    • Add/Edit DefaultPassword set to users password (if the value does not exist, add it by right clicking WinLogon and choosing New > "String Value"
  • Restart the computer.

Points of Interest

  • When the first test run starts, the test run server will restart and auto login as the user and work, even if the user was already auto logged in. But also as long as you do not remote into the computer or change it in any way, subsequent logins will no longer restart that computer. If you do not disable the lock screen, it will restart every time as it will be locked.
  • Using Hyper-V, there is a small view of the desktop of the computer so you can tell what state the computer is in, i.e., logged in or running tests or restarting, etc.
  • Reinstalling any version of a test agent will remove registry setting for Default Password, I have not seen it modify the auto admin login setting, the domain or the default user. Also, the group policy lock does not seem to be effected. I am unsure how this will be effected if you let the Deploy Test Agent Task install the agent.
  • I manually install the agents on the server and uncheck Update Test Agent. This stops the system from downloading the agent and saves time if you have a slow network.

History

Changed information for setting up DefaultPassword. Previously said "add new key", changed to "New > "String Value"". The entry is a String Value, not a Key.

License

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


Written By
Software Developer
United States United States
I am currently an Automation Developer working on Coded UI Frameworks using Selenium, Load Testing Frameworks and Dynamic Data Frameworks for the prior mentioned testing systems. I maintain all of the software and hardware for our build, release and test systems, mostly using TFS, powershell and Hyper-V as well as building and maintaining Automated test systems.

Skills
SQL, Software Development, Microsoft SQL Server, Agile Methodologies
C#, JavaScript, HTML, C++, Markdown, XAML, XML
Quality Testing, Coded UI Testing, Selenium Testing, Load Testing
ALM, Team Foundation Server/VSO, Build Administration
Databases SQL/Oracle, Software and Hardware Installation/Maintenance
Troubleshooting, Project Management,
Solid State Electronics, Pulse Width Modulation, Metal Casting, Carbon Fiber Casting, Powder Coating.

Comments and Discussions

 
-- There are no messages in this forum --