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

[java] Add missing support events for Web Driver Listener #13210

Merged
merged 5 commits into from
Jan 24, 2024

Conversation

RevealOscar
Copy link
Contributor

Thanks for contributing to Selenium!
A PR well described will help maintainers to quickly review and merge it

Before submitting your PR, please check our contributing guidelines.
Avoid large PRs, help reviewers by making them as simple and short as possible.

Description

adds explicit target locator events to the listener support classes. This can already be done implicitly since events can resolve to the web driver instance but this exposes these events explicitly

Motivation and Context

Types of changes

  • 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 change)

Checklist

  • I have read the contributing document.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

* @param driver WebDriver
*/
default void afterWindow(
WebDriver.TargetLocator targetLocator, String nameOrHandle, WebDriver driver) {}
Copy link
Contributor

Choose a reason for hiding this comment

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

would you mind adding hooks for all methods from TargetLocator?

@codecov-commenter
Copy link

codecov-commenter commented Nov 28, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (9a044b8) 58.48% compared to head (954eb4a) 58.48%.
Report is 7 commits behind head on trunk.

❗ Current head 954eb4a differs from pull request most recent head cd4b4f5. Consider uploading reports for the commit cd4b4f5 to get more accurate results

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff           @@
##            trunk   #13210   +/-   ##
=======================================
  Coverage   58.48%   58.48%           
=======================================
  Files          86       86           
  Lines        5270     5270           
  Branches      220      220           
=======================================
  Hits         3082     3082           
  Misses       1968     1968           
  Partials      220      220           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@titusfortner
Copy link
Member

@titusfortner titusfortner added this to the 4.17 milestone Dec 1, 2023
@titusfortner
Copy link
Member

@valfirst & @RevealOscar thanks for your work and interest on this. Just sending a reminder that we want to get this into the next release if either of you have bandwidth to work on it this week. Thanks again.

@martingrossmann
Copy link

For my understanding:
Is afterWindow the new version of WebDriverEventListener.afterSwitchToWindow()?

@titusfortner
Copy link
Member

Yes it pulls the name of the actual method being called, which is window()

@titusfortner
Copy link
Member

@valfirst & @RevealOscar another ping on getting this added before 4.17 release, which will be "soon"
Thanks again for your help!

@titusfortner titusfortner modified the milestones: 4.17, 4.18 Jan 22, 2024
@valfirst
Copy link
Contributor

valfirst commented Jan 23, 2024

@titusfortner I don't have permissions to work on this PR.

if @RevealOscar doesn't have capacity to complete the PR, I would merge it as is (it's better than nothing). Then next contributor can add missing functionalities in a separate PR.

@diemol
Copy link
Member

diemol commented Jan 23, 2024

@RevealOscar could you please resolve the conflicts and then I can merge this?

@titusfortner
Copy link
Member

it was just imports conflicting, if there's a problem RBE will fail 😂

Copy link
Member

@diemol diemol left a comment

Choose a reason for hiding this comment

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

Thank you all!

@diemol diemol merged commit b5259d8 into SeleniumHQ:trunk Jan 24, 2024
39 of 40 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants