Quirks of driving a native app through the DOM mirror that a web test wouldn't expect.
- Only the screen you are on is mirrored. iOS keeps a screen in the hierarchy after the app navigates away, so a stale login form — credentials still in its fields — would otherwise show up on every following screen. Those are culled: a selector can't resolve to an invisible screen and fail silently.
- Text fields are real
<input>elements, sofill(),inputValue(), andtoHaveValue()work as on any page — as does thebrowser_typean agent reaches for. A field's contents live in its value, not its text — the one place the mirror departs from "every native node is a div". - Typing is verified.
fill()sets the text through the device's driver and returns once the device holds the value, so the next action can submit straight away. The device's read-back is ondata-dd-device-value(a secure field reports bullets).keyboard.typestill works, key by key, but on Android it raises the soft keyboard and the next tap can be spent closing it — preferfill(). - A fresh launch is the clean slate. A native app stays logged in across a raw relaunch;
POST /app/launchwipes app data by default (pass?reset=noto resume where it was left). - Device-only controls live on
window.devicedeck:gesture('home' | 'appSwitcher' | …),swipe,button,key, andscreenshot()(the device screen as a PNG data URL). Call them viapage.evaluate— the device page<title>lists the gesture set.