selenium web driver on windows 7 parallels vm - browser hidden - allow service to interact with desktop?

StackOverflow https://stackoverflow.com/questions/17369205

Domanda

I am using a script on my mac host to launch a selenium node on a local parallels VM.

Something like

"prlctl exec Win7-VM-Name-Here 'C:\path_here\start_node.bat'"

The node starts up nicely and registers itself with the hub. I can run tests fine against this node.

However, when the tests are running, the browser is not visible on the VM, which means that screenshots are useless.

I think it has something to do with allowing a service to interact with the desktop, but I can't figure out which one, or how to proceed.

Any help?

Thank you.

È stato utile?

Soluzione

Unfortunately, this is a common problem with selenium (or any other browser automation software) on Windows. If selenium is running in the background as a service, the browser will not appear when the tests are being run and taking screenshots will just result in a black picture. If you want to be able to watch the tests being run and grab screenshots, the general consensus is to start your script manually from the command line and leave it running.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top