Tests will fail if close the remote window for VM

Experiences, small talk, and other automation gossip.
yydpkm
Posts: 14
Joined: Wed Jul 12, 2017 8:33 pm

Tests will fail if close the remote window for VM

Post by yydpkm » Mon Jul 24, 2017 2:32 pm

I am aware Ranorex need an active user session to work on VM.

What I did so far:
I tried minimize the Remote Desktop Connection window, almost all tests failed.
I tried keep the Remote Desktop Connection window open and then close the monitor, almost all tests failed.
It can only work fine if I keep the Remote Desktop Connection window open and stare at the screen. :evil:
This is clearly not the purpose to do test automation.

Is there any solution to this? Or the only way to let it run on VM is open the remote window and monitor on?

Ranorex 5.2.2. I am not allowed to update Ranorex.
OS windows server 2008 R2.

Thanks guys. :D

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 7470
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: Tests will fail if close the remote window for VM

Post by odklizec » Mon Jul 24, 2017 2:46 pm

Hi,

It's a security behavior of Remote Desktop. It simply must be open and not minimized! You must either switch from RDP to VNC (it keeps connection even if closed), or configure proper continuous integration system (like Jenkins), which keeps the slave machines online.
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

a.s
Posts: 7
Joined: Thu Jul 06, 2017 3:25 pm

Re: Tests will fail if close the remote window for VM

Post by a.s » Wed Aug 09, 2017 3:19 pm

you might want to have a look at the tscon commandline tool.
this tool disconnects your remote desktop connection while keeping the session running on your VM.
works pretty good in my environment.

regards
alex