0

I am running coded UI tests using Selenium from a build in VSTS. The test library is built on a test agent (hosted and private available) and copied to a VM running Windows 10. Then the test agent is deployed to the VM and the task 'Run Functional Tests' is executed. The tests to be executed are selected through an association in the test manager of VSTS.

I would like to run these UI tests (in Chrome) in different screen resolutions, but when the test agent is executed, the headless session always runs in the default resolution of 1024x768. I need to run tests up to a 4k resolution. If there is a current session with the same credentials in a higher resolution, this session is "hijacked" and the tests run in the desired resolution. But I cannot guarantee an existing session when those builds are triggers by either a schedule or another event. I already followed an MSDN article how to specify a default resolution in the registry, but that doesn't work on neither Win10 nor on Srv2012.

Is there a parameter/setting in a test/run setting file that specifies the resolution of this headless session? To avoid confusion: I know how to set the windows size of the browser, but that is limited to the maximum screen resolution, so the Selenium-specific commands to resize the browser don't do the trick ;)

Any hint appreciated! Thanks!

Nessi
  • 139
  • 7
  • 1
    Are you running Coded UI tests, or are you running Selenium tests? They're different tools that do the same thing. – Daniel Mann Oct 19 '17 at 15:29
  • Apologies. I was under impression that a coded UI test is a generic expression as one uses code to describe a UI test. So to clarify: I am using Selenium. Thanks, Daniel, for pointing that out. – Nessi Oct 19 '17 at 19:04
  • I am afraid that you can't change resolution unless keep the session, a related thread: [Increase the screen resolution on Test Agent](https://stackoverflow.com/questions/45829787/increase-the-screen-resolution-on-test-agent) – starian chen-MSFT Oct 20 '17 at 07:48

0 Answers0