Skip to content

Commit dd067b8

Browse files
thymikeeclaude
andcommitted
fix(runner): restore the discriminating window-content rows and the retap skip reason
Put back the moved-window, keyboard, and SpringBoard rows in windowContentCases, and log one skip line carrying its reason when the readiness retap names no screen point. Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent 07343ad commit dd067b8

2 files changed

Lines changed: 22 additions & 1 deletion

File tree

‎apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+TextEntryReadiness.swift‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,10 @@ extension RunnerTests {
101101

102102
/// The readiness repeat, at the read's screen box; a read that names none taps nothing (#3899).
103103
func retapAt(read: ResolvedTextEntryInput, app: XCUIApplication, element: XCUIElement) {
104-
guard let frame = read.frameOnScreen, !frame.isEmpty else { return }
104+
guard let frame = read.frameOnScreen, !frame.isEmpty else {
105+
NSLog("AGENT_DEVICE_RUNNER_TEXT_ENTRY_RETAP skipped reason=%@", read.frameOnScreen == nil ? "no-screen-frame" : "empty-frame")
106+
return
107+
}
105108
NSLog("AGENT_DEVICE_RUNNER_TEXT_ENTRY_RETAP x=%.1f y=%.1f", frame.midX, frame.midY)
106109
_ = tapAt(app: app, x: frame.midX, y: frame.midY)
107110
_ = waitForTextEntryFocus(app: app, element: element, timeout: TextEntryTiming.readinessTimeout)

‎contracts/fixtures/window-coordinate-space.json‎

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,24 @@
175175
"viewportBox": { "x": 224, "y": 207, "width": 386, "height": 682 },
176176
"offset": { "width": 224, "height": 207 }
177177
},
178+
{
179+
"name": "the same window moved elsewhere on the screen carries its subtree by the new origin",
180+
"reportedBox": { "x": 0, "y": 0, "width": 386, "height": 682 },
181+
"viewportBox": { "x": 120, "y": 90, "width": 386, "height": 682 },
182+
"offset": { "width": 120, "height": 90 }
183+
},
184+
{
185+
"name": "the keyboard window under a windowed app reports the screen's box and stays in screen space",
186+
"reportedBox": { "x": 0, "y": 925, "width": 834, "height": 282 },
187+
"viewportBox": { "x": 224, "y": 207, "width": 386, "height": 682 },
188+
"offset": null
189+
},
190+
{
191+
"name": "a SpringBoard overlay under a windowed app reports the whole screen and translates nothing",
192+
"reportedBox": { "x": 0, "y": 0, "width": 834, "height": 1210 },
193+
"viewportBox": { "x": 224, "y": 207, "width": 386, "height": 682 },
194+
"offset": null
195+
},
178196
{
179197
"name": "the app's own window box reports the screen box it is placed at and translates nothing",
180198
"reportedBox": { "x": 224, "y": 207, "width": 386, "height": 682 },

0 commit comments

Comments
 (0)