Commit 81fc22d47b
Verified · cmc
Layout: unified · split
gitbayUITests/LiveSmokeUITests.swift +6 −1
| @@ -1949,7 +1949,12 @@ extension LiveSmokeUITests { | |||
| 1949 | 1949 | ||
| 1950 | // Kept on success too: this is how the preview's look is checked | 1950 | // Kept on success too: this is how the preview's look is checked |
| 1951 | // in light and dark without signing a simulator in by hand. | 1951 | // in light and dark without signing a simulator in by hand. |
| 1952 | for _ in 0..<3 where !rendered.isHittable { app.swipeUp() } | 1952 | // isHittable is true behind the keyboard, which is its own window; |
| 1953 | // compare frames so the screenshot shows the rendering. | ||
| 1954 | let keyboard = app.keyboards.firstMatch | ||
| 1955 | for _ in 0..<3 where keyboard.exists && rendered.frame.maxY > keyboard.frame.minY { | ||
| 1956 | app.swipeUp() | ||
| 1957 | } | ||
| 1953 | let shot = XCTAttachment(screenshot: app.screenshot()) | 1958 | let shot = XCTAttachment(screenshot: app.screenshot()) |
| 1954 | shot.name = "markup preview" | 1959 | shot.name = "markup preview" |
| 1955 | shot.lifetime = .keepAlways | 1960 | shot.lifetime = .keepAlways |