Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/support selenium 4 #292

Merged
merged 77 commits into from
Aug 17, 2023
Merged

Conversation

martingrossmann
Copy link
Contributor

@martingrossmann martingrossmann commented Nov 30, 2022

Description

  • Upgraded the Selenium version to 4.10.0 🚀
  • Removed support for phantomJS
  • Changed internal handling of browser capabilities: Now the specific browser options are used to create sessions. All other capabilties (global or from DesktopWebDriverRequest) are merged into browser options. (also see Selenium Browser Options)
  • Added support for Chrome Dev Tools for local and remote Webdriver sessions

This PR replaces #210 because this is based on Testerra 2.

Fixes #285

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

@martingrossmann martingrossmann mentioned this pull request Nov 30, 2022
11 tasks

WEB_DRIVER_MANAGER.removeGlobalCapability("t04Global");

SessionContext sessionContext = WEB_DRIVER_MANAGER.getSessionContext(driver).get();
Copy link

Choose a reason for hiding this comment

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

@SuppressWarnings("OptionalGetWithoutIsPresent")?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

There must be a session context, otherwise the test will fail.

Copy link

Choose a reason for hiding this comment

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

Yes, thence I suggest to suppress the warning. It helps keeping warnings relevant. ... Feel free to skip though - I did not check for this thoroughly, just noticed because I had the file open anyway.

… feature/support-selenium-4

# Conflicts:
#	build.gradle
# Conflicts:
#	driver-ui-desktop/src/main/java/eu/tsystems/mms/tic/testframework/webdrivermanager/DesktopWebDriverFactory.java
#	driver-ui/src/main/java/eu/tsystems/mms/tic/testframework/webdrivermanager/AbstractWebDriverRequest.java
#	integration-tests/src/test/java/eu/tsystems/mms/tic/testframework/test/webdrivermanager/DesktopWebDriverFactoryTest.java
# Conflicts:
#	driver-ui/src/main/java/eu/tsystems/mms/tic/testframework/utils/DefaultCapabilityUtils.java
#	integration-tests/src/test/java/eu/tsystems/mms/tic/testframework/playground/DriverAndGuiElementTest.java
#	integration-tests/src/test/java/eu/tsystems/mms/tic/testframework/test/webdrivermanager/DesktopWebDriverFactoryTest.java
@martingrossmann martingrossmann marked this pull request as ready for review July 27, 2023 15:36
@@ -28,7 +28,5 @@ public class Browsers {
public static final String ie = "ie";

Choose a reason for hiding this comment

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

Is ie browser still needed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good question. I think nobody will use it any more but it is still part of Selenium: https://www.selenium.dev/documentation/webdriver/browsers/internet_explorer/

@@ -15,8 +15,6 @@ The following types of browsers are supported:
* ie

Choose a reason for hiding this comment

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

Is ie browser still needed?

# Conflicts:
#	integration-tests/src/test/java/eu/tsystems/mms/tic/testframework/playground/DriverAndGuiElementTest.java
#	integration-tests/src/test/java/io/testerra/test/status/CheckTestStatusTest.java
@martingrossmann martingrossmann merged commit 5fc8e9e into master Aug 17, 2023
@martingrossmann martingrossmann deleted the feature/support-selenium-4 branch August 17, 2023 09:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Request capabilities does not overwrite global browser capabilites
4 participants