Release Management
Last active
February 15, 2018 15:39
-
-
Save ennisa-ire/0f2dc50ffba69f095d602d266f21fee8 to your computer and use it in GitHub Desktop.
00 - IoT Tech Operations Corner
Chrome was installed not in program files directory and as such, it was not been found. For this reason it was ness. to use chrome options to set the path
ChromeOptions options = new ChromeOptions();
options.setBinary("C:\\ProgramData\\Microsoft\\AppV\\Client\\Integration\\0BDBB826-0111-4240-9B49-E6B877ACA833\\Root\\VFS\\ProgramFilesX86\\Google\\Chrome\\Application");
Second the driver would not spin up, as chromedriver uses the wire protocol, you can sping up chrome driver as an agent, and set the driver in code up remotely
So got to the directory where you have put chromedriver.exe and start it up, this will spin up a dos window. The window will default to port 9515, which you use in your remote call.
DesiredCapabilities capabilities = DesiredCapabilities.chrome();
driver = new RemoteWebDriver(new URL("http://localhost:9515"), capabilities);
souce code is here
https://github.com/ennisa-ire/aib_ops_ux.git
<dependencies>
<dependency>
<groupId>org.testng</groupId>
<artifactId>testng</artifactId>
<version>RELEASE</version>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-api</artifactId>
<version>RELEASE</version>
</dependency>
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-java</artifactId>
<version>2.45.0</version>
</dependency>
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-api</artifactId>
<version>2.45.0</version>
</dependency>
</dependencies>
This use the geckco driver. You could also try the remote driver approach here?
Not advised anymore, as FF and Chrome have headless capabilities.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment