Graphene integrates with Arquillian Drone to simplify process of instantiation of browser session.
So Drone takes care of WebDriver instance creation and configuration and then it delegates this session to Graphene.
Graphene shares the configuration with Drone WebDriver, so you can refer to Drone.
In general, configuration is driven by arquillian.xml and can be overriden by System properties.
You can ask Drone to instantiate any specific implementation of WebDriver like FirefoxDriver, ChromeDriver or HtmlUnitDriver, e.g.:
But it is recommended to use WebDriver interface and use arquillian.xml to choose appropriate browser instance:
In order to speed up development, Drone comes with Reusable Remote WebDriver Session feature.
This feature make sure that Drone does not close the browser session on the end of each test,
and it stores the session handle in the pernament storage.
Thus after running first test, browser session is still open and next tests can reuse it.
Since browser session does not have to be opened repeatedly, Drone saves this time
and repeating a test leads into huge time savings.
This enables browser automated tests development as close to unit tests execution time as possible.
Since session is not closed at the end of test, you can tweak anything in browser setup you want including setup of browser debuggers (Firebug, Chrome Dev Tools).
You can for example:
- open debugger and watch network usage
- insert breakpoints to scripts
- watch browser console
This feature is available only when using remote WebDriver session. So you need to download appropriate version of Selenium Server and start the server:
Now Drone can connect to this server and share the session-id across several tests.
You can turn on Reusable Browser Session by following entry: