Best Practice Headless Web Driver
Posted: Tue May 22, 2018 10:29 am
Hello,
I'm want to automate our web testing setup and have a general question for my setup.
I want to test our test cases against different browsers with different browser sizes. As the test will run in Jenkins on a machine without graphical interface I need to use headless browsers for chrome and firefox.
I set an endpoint for chrome using:
capabilities: {
browserName: 'chrome',
chromeOptions: {
args: ['headless', 'window-size=1920,1080']
}
}
Can i use different configurations when starting the ".exe"? Or do I use a different approach?
Or do I write a custom function and pass the arguments i.e.:
Host.Current.OpenBrowser(pageUrl," 'headless', 'window-size=1920,1080' ",false,true,false,false,false);
(However, the arguments are not used, when starting the browser on an endpoint).
Thanks for your help.
I'm want to automate our web testing setup and have a general question for my setup.
I want to test our test cases against different browsers with different browser sizes. As the test will run in Jenkins on a machine without graphical interface I need to use headless browsers for chrome and firefox.
I set an endpoint for chrome using:
capabilities: {
browserName: 'chrome',
chromeOptions: {
args: ['headless', 'window-size=1920,1080']
}
}
Can i use different configurations when starting the ".exe"? Or do I use a different approach?
Or do I write a custom function and pass the arguments i.e.:
Host.Current.OpenBrowser(pageUrl," 'headless', 'window-size=1920,1080' ",false,true,false,false,false);
(However, the arguments are not used, when starting the browser on an endpoint).
Thanks for your help.