How to find chrome driver version in use for a node on a Selenium grid
Asked Answered
N

1

9

Is there a way to check the chrome driver version in use on a particular node remotely?

I know running chromedriver.exe -v directly on the node will report the driver version. But is there any way to query this through the selenium grid api?

I've looked at the useful information here but I can't see a way to do it: https://github.com/nicegraham/selenium-grid2-api

Or ideally I'd like to see this displayed on configuration tab of the selenium grid console for each node.

Maybe there's a way to display this as an extra property I add to the configuration by capturing the output of running capture the output of chromedriver.exe -v prior to connecting the node to the grid?

Niobium answered 24/2, 2017 at 10:21 Comment(0)
E
8

If you have a configuration file for your node you can add the currently running/deployed chromedriver version to that and than it will be shown in the Configuration tab.
I added the chromedriver version by hand, but you can easily add this during deployment of the node.

Configuration file with capabilities

This way it will be displayed in the capabilities section of the Configuration tab in your /grid/console.

Capabilities with chromedriver version

PS: If you need the Chromedriver version during runtime of your code you can get it with driver.getCapabilities().getCapability("chrome") and than parse the chromedriverVersion with a RegEx.

Enlightenment answered 24/2, 2017 at 11:10 Comment(1)
Using Protractor (Angular) I had to use: let cap = browser.driver.getCapabilities().then(c => c.get("chrome")); console.log(await cap);Hair

© 2022 - 2024 — McMap. All rights reserved.