Hi,
Did you try to use the same method on the remote driver with the help of selenium grid? My application is an electron-based messaging application and needs to send-receive message between two application. I can do anything on my local machine by webdriver, such as; sending IMs, using all the buttons, login-logout etc. but when it comes to using the remote driver which is set for the node machine, even though app's binary is invoked and the app is launched, the remote driver cannot do anything,
I am always getting the same error;
Caused by: org.openqa.selenium.WebDriverException: unknown error: DevToolsActivePort file doesn't exist
(Driver info: chromedriver=2.42.591088 (7b2b2dca23cca0862f674758c9a3933e685c27d5),platform=Windows NT 10.0.14393 x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 60.27 seconds
public class remotetest {
WebDriver Rdriver;
@Test
public void launch() throws InterruptedException, IOException {
System.setProperty("webdriver.chrome.driver","D:\\work\\grid\\chromedriver.exe"); // chromedriver path
ChromeOptions options = new ChromeOptions();
options.setBinary("D:\\Users\\myol\\AppData\\Local\\Programs\\ConnectMe_S4B2015\\Connect Me S4B2015.exe");
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability(ChromeOptions.CAPABILITY, options);
capabilities.setBrowserName("chrome");
capabilities.setPlatform(Platform.WINDOWS);
WebDriver Rdriver = new RemoteWebDriver(new URL("http://localhost:4444/wd/hub"), capabilities);
for (String hand : Rdriver.getWindowHandles()) {
Rdriver.switchTo().window(hand);
}