Search code examples
network-programmingcross-domainautomated-testsworkgroup

Setup Visual Studio 2013 Test Agents and Controllers on Workgroup Windows 10 Tablets


I am looking to run automated Coded UI test cases on a specific test environment, and am running into issues when setting up our Test Agent and Test Controller.

Specifically, I am getting a "no such host known" error when trying to connect my agent to the controller.

This is the setup I'm using for the test environment:

  1. There are 2 to 25 individual tablets I'm looking to connect in total, though just 2 for now
  2. Each tablet has an image placed on it, so all have the same setup
  3. The image is in a Workgroup and not a domain
  4. The tablets talk to one another through a router that doesn't have an internet connection
  5. With no internet connection, my intent is to use Visual Studio on one of the tablets to manage the test controller and subsequently execute the tests from it on the closed router network
  6. This also means that I won't be utilizing a TFS with my test controller. Likewise, I won't be using Test Manager to manage the test controller and agents.

I believe my issue stems from using the wrong controller registration string with the agent, though I'm unsure of what it is supposed to be.

I've tried the recommended "ControllerMachineName:6901" but I have received the same error mentioned above.

The 2 tablets are able to ping one another on the router by IP address, so they for sure can communicate. I did find though that trying to ping by their Machine Name doesn't work, so I am suspecting this is why the agent to controller string doesn't work.

I tried using "IPAddress:6901" with the agent instead, but I received the same error.

Other things I've tried:

  1. Added a domain user from our network to 2 of the tablets and used those credentials with the controller and agent. Received same error. This setup was to try and mimic the recommended setup described in Microsoft's documentation (i.e. same domain setup on multiple devices)
  2. Tried creating "shadow" accounts as recommended in Microsoft's agent and controller workgroup documentation, where the 2 tablets both have the same user accounts and passwords. With the controller and agent using different user accounts (but with both available on both tablets still), the connection is supposed to work; I received the same error in this case too though
  3. I checked the router and no special restrictions are being placed on messages/connections through it
  4. I checked the local firewalls on the tablets and made sure the agent and controller were being allowed
  5. I checked File and Printer Sharing on the local firewalls and it was set to be allowed
  6. Ensured the user account on the agent tablet had permissions in the correct controller user groups

Does anyone know if the issue is because these tablets are on a workgroup, or if the connection string I'm using is the problem?


Solution

  • So it looks like with a mix of all of the solutions posted and things I tried, somehow the Host file setting wasn't actually working.

    I did the following though and was able to solve the issue:

    1. With freshly imaged tablets, I installed the agent on one and the controller on the other
    2. I connected both to my router
    3. I set the Host file on the controller machine to include the IP address and computer name of the agent machine
    4. I set the Host file on the agent machine to include the IP address and computer name of the controller machine
    5. I setup configured the controller with an admin user account
    6. I configured the agent using the same admin account, and with the controller connection string MachineName:6901
    7. After running the agent, it was able to successfully connect to the controller without issue

    Just to be clear too on where the host file is located (as I saw others post this solution without where it was), it can be found in C:\Windows\System32\drivers\etc, and can be edited in Notepad.