简体   繁体   中英

Selenium webdriver Jenkins slave black screenshots on IE

I have a jenkins setup with windows 7 slaves.

The slaves run as a service that starts on logon as a user.

When running selenium webdriver tests on IE versions locally on the slaves everything works fine and the screenshots turns out fine.

When I run the tests via jenkins from the master, the tests run fine, but all screenshots from IE are entirely black.

Firefox works fine and so does chrome.

The slaves a logged in, not locked and with no screensaver.

Some suggestion is that the service is run as local account and "Allow service to interact with desktop" as in this guide:

http://ausavchuk.blogspot.ru/2013/05/screenshots-for-headless-configuration.html

But if I run it as a local account and not a user, the tests won`t even start.

How do I fix the IE screenshots?

Found a solution:

instead of running it as a service i put this: (remove the space after http://)

javaws http:// [LINK TO MASTER SERVER]/jenkins/computer/[SLAVE NAME]/slave-agent.jnlp

into a bat file and put that into windows startup.

This makes IE browsers run non-hidden instead of hidden and screenshots will work just as if running locally.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM