Skip to content
This repository was archived by the owner on Feb 2, 2025. It is now read-only.

added webdrivermanager of io.github.bonigarcia library interaction #73

Merged
merged 5 commits into from
Jul 9, 2019

Conversation

YauheniPo
Copy link
Contributor

No description provided.

@Hi-Fi
Copy link
Collaborator

Hi-Fi commented Jun 29, 2019

Thank you, this shows really interesting but I have to check code a bit more. Currently webdriver need is handled by Maven with https://github.com/Ardesco/selenium-standalone-server-plugin (that allows usage of local repos for stricter network access).

@YauheniPo
Copy link
Contributor Author

I am using your framework for my test project and I updated and added some functions for my tests actions.
https://github.com/YauheniPo/RobotFramework_GUI_Tests

@YauheniPo
Copy link
Contributor Author

If I do not use my solution I have

Setup failed:
java.lang.IllegalStateException: The path to the driver executable must be set by the webdriver.chrome.driver system property; for more information, see https://github.com/SeleniumHQ/selenium/wiki/ChromeDriver. The latest version can be downloaded from http://chromedriver.storage.googleapis.com/index.html

What do you think?

@Hi-Fi
Copy link
Collaborator

Hi-Fi commented Jul 1, 2019

As said, currently I'm using self in tests (and that way instructing others) to use Maven to handle the dependencies including Webdriver (https://github.com/Hi-Fi/robotframework-seleniumlibrary-java/blob/develop/pom.xml#L202). That of course requires that things are running with Maven and not using stand-alone jar. For latter one your solution is fine, but I have to check at code side the implementation, and if the release with new keywords related to webdriver binaries should be released still with Selenium 3 or along with Selenium 4 (alpha) release.

String browserName = robot.getParamsValue(args, 0, "firefox");
String alias = robot.getParamsValue(args, 1, "None");
String remoteUrl = robot.getParamsValue(args, 2, "None");
String desiredCapabilities = robot.getParamsValue(args, 3, "None");
String browserOptions = robot.getParamsValue(args, 4, "None");
String webDriverManager = robot.getParamsValue(args, 5, "None");

if (!webDriverManager.equals("None")) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be cleaner, if Robot -class itself would take boolean as a default, and use Boolean value also here as there's no usage of String value in this case.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@@ -184,17 +186,17 @@ public void closeBrowser() {
"| `Open Browser` | http://example.com | Edge | remote_url=http://127.0.0.1:4444/wd/hub |\r\n" +
"\r\n" +
"If the provided configuration options are not enough, it is possible to use `Create Webdriver` to customize browser initialization even more.")
@ArgumentNames({ "url", "browserName=firefox", "alias=None", "remoteUrl=None", "desiredCapabilities=None",
"browserOptions=None", "webDriverManager=None" })
@ArgumentNames({ "url", "browserName=firefox", "isWebDriverManager=false", "alias=None", "remoteUrl=None",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changing of the order is problematic, as it could break the compatibility if place specific arguments are already used. New ones should go to end.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@Hi-Fi Hi-Fi merged commit 849b542 into MarketSquare:develop Jul 9, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants