Following is my code:
DesiredCapabilities cap = DesiredCapabilities.chrome();
ChromeOptions options = new ChromeOptions();
options.setExperimentalOption("useAutomationExtension", false);
options.addArguments("--headless");
cap.setCapability(ChromeOptions.CAPABILITY, options);
driver = new RemoteWebDriver(new URL("http://localhost:4444/wd/hub/"), cap);
wait = new WebDriverWait(driver, 10);
If I go to google.com using driver.get(url) & take a screenshot, I can see the Google Page, but as soon as I try to open the GWT app, i only get a white page and the following source printed with System.out.println(driver.getPageSource());
<html xmlns="http://www.w3.org/1999/xhtml"><head>
<title>Secure Login Service</title>
</head>
<body>
But the monent I remove the headless flag, chrome starts and the GWT app loads normally
I'm running Chrome-Version 63.0.3239.84, selenium-server-standalone-3.5.3, chromedriver 2.33 & Windows 7 Enterprise 64bit.
I'm unable to update Chrome, but I can try different versions of selenium-driver and chromedriver (I tried other versions but they wouldn't run - but thats another topic) - Is there another good headless-Browser which needs no installation (i.e. awesomeHeadlessBrowser.jar?)
Any suggestion would be appreciated.