• python
  • javascript
  • reactjs
  • sql
  • c#
  • java
Facebook Twitter Instagram
Devs Fixed
  • python
  • javascript
  • reactjs
  • sql
  • c#
  • java
Devs Fixed
Home ยป Resolved: How to get the browser and driver Version in Selenium C#

Resolved: How to get the browser and driver Version in Selenium C#

0
By Isaac Tonny on 16/03/2023 Issue
Share
Facebook Twitter LinkedIn

In this post, we will see how to resolve How to get the browser and driver Version in Selenium C#

Question:

In C# we use the ICapabilities cap =new ICapabilities; to get the browser version or the driver version. When I run the code in a console application before the application run in the console information is printed there like the driver has started successfully and the driver version is also printed so as the browser version I would like to get that information that is printed on the console since if I wanted to check the browser version using a older driver the application won’t run which in turn means my code I have written to check the browser version won’t run to give me the results back. The question is there a way I can get the version of the driver from the output that is printed on the console before the application runs. I would like to do some automation where I can pair the browser version with the same driver version.

Best Answer:

I don’t think you can do this before you start the application. And even though there should be an API to check the driver version and the browser version, it shouldn’t be a matter of Selenium.
The only possible way to fulfill this purpose that I can come up with is to check their versions manually like this:
And then you can compare their versions.

If you have better answer, please add a comment about this, thank you!

Source: Stackoverflow.com

automated-tests c# microsoft-edge selenium-webdriver
Share. Facebook Twitter LinkedIn

Related Posts

Resolved: Visual Studio 2022 crashes when using breakpoints

24/03/2023

Resolved: How to get Union type from an array of objects in Flow?

24/03/2023

Resolved: Modify entity using Action in C#

24/03/2023

Comments are closed.

© 2023 DEVSFIX.COM

Type above and press Enter to search. Press Esc to cancel.