Conversation
|
Warning Review limit reached
This review includes 16 billable files and costs up to $4.00.
Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing. Or wait 2 minutes for your next included review. View limit detailsLimit details: You’ve used all 2 included reviews currently available. Your 57 included PR review attempts over the past 7 days set your current allowance at 2 reviews per hour. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Essentials Run ID: 📒 Files selected for processing (16)
Comment |
3 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Adds Playwright-style dialog handling:
screen.on('dialog', d => d.accept()). Android only for now; iOS comes next.How it works
Screenwraps the driver'sgetViewHierarchy(). Every locator poll andexpect()retry already fetches the tree (every 100ms), so with a listener registered each fetch also checks for a dialog, at no extra device cost.identifier, the same ids Appium's UiAutomator2 server uses:android:id/button1..3,:id/alertTitle,android:id/message:id/permission_message,:id/permission_*_button(accept = first_allow_, dismiss =_deny_)API
screen.on/once/off('dialog', handler)Dialog:type()(alert/confirm/prompt/permission),isSystem(),title(),message(),buttons(),accept(promptText?),dismiss(),tap(name)device.clearAppData(bundleId)→ mobileclidevice.apps.clear. On Android this also resets runtime permissions, including "don't ask again", so permission prompts show again on every run. Added to the driver protocol and both drivers.accept(text)on a prompt finds the OK button again after typing, because the keyboard pushes the dialog up (410px on a Pixel 9a).Docs: new
guides/dialogspage.Test plan
dialog.test.ts; all 798 core unit tests passnpm run linte2e/src/android/dialogs.test.ts(8 tests: confirm, prompt, tap by caption, delayed alert, alert covering a tap target, location/camera/notifications prompts) passes 3 runs in a row on a Pixel 9a emulator (API 37)