feat(android): Add android connection implementation #1799
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
resolves #1789
This pull request introduces initial support for connecting to Android devices in the Playwright Java client. It represents the first step in a possible series of contributions intended to bring Android automation capabilities—currently available in the Node.js client—to the Java ecosystem.
Although the related issue was recently marked as not planned, I fully understand and respect the project's priorities. That said, I hope this contribution might be helpful as a starting point should there be interest in revisiting the discussion around Android support in the future.
Changes Made
Android
interface and its implementationAndroidDevice
Connection
andPlaywright
to integrate the android flow.Motivation
Bringing Android support to the Java client could help broaden Playwright's reach among teams working with mobile platforms and Java-based test infrastructure. The ability to automate Android devices is already supported in the Node.js client and opens up valuable use cases such as:
This pull request focuses solely on connection support to ensure changes remain focused, reviewable, and easy to build upon incrementally.
Testing
Notes
A complete implementation of Android support for the Java client has been developed and tested locally. I’m submitting this first PR with the intention of contributing incrementally and being as respectful as possible of the project’s review process.
I sincerely welcome any feedback, suggestions, or direction on how best to align this work with the project’s goals and standards. Thank you for taking the time to consider this contribution.