diff --git a/.maestro/features/06-swipe-undo.yaml b/.maestro/features/06-swipe-undo.yaml index ff5159a8..e19a97c2 100644 --- a/.maestro/features/06-swipe-undo.yaml +++ b/.maestro/features/06-swipe-undo.yaml @@ -15,14 +15,11 @@ tags: from: ".*Grüße aus München.*" direction: LEFT duration: 400 -- extendedWaitUntil: - visible: "Email archived" - timeout: 10000 -- takeScreenshot: swipe-01-archived -- assertNotVisible: ".*Grüße aus München.*" +# The undo bar shows for 5 s; when it goes, the Compose button slides into +# its place, and a late tap on UNDO opens the composer. So tap at once and +# check the rest afterwards. - tapOn: text: "UNDO" - # The undo bar shows for 5 s: don't spend them waiting for the screen to settle. waitToSettleTimeoutMs: 500 - extendedWaitUntil: visible: ".*Grüße aus München.*" diff --git a/.maestro/features/07-move-delete-tag.yaml b/.maestro/features/07-move-delete-tag.yaml index d55e23ac..38dfc5d9 100644 --- a/.maestro/features/07-move-delete-tag.yaml +++ b/.maestro/features/07-move-delete-tag.yaml @@ -25,10 +25,8 @@ tags: text: "Projects" # The undo bar shows for 5 s: don't spend them waiting for the screen to settle. waitToSettleTimeoutMs: 500 -- extendedWaitUntil: - visible: "Moved to Projects" - timeout: 15000 - takeScreenshot: actions-02-moved +# Tap UNDO at once (see 06-swipe-undo: a late tap opens the composer). - tapOn: text: "UNDO" # The undo bar shows for 5 s: don't spend them waiting for the screen to settle. @@ -48,9 +46,6 @@ tags: text: "Delete" # The undo bar shows for 5 s: don't spend them waiting for the screen to settle. waitToSettleTimeoutMs: 500 -- extendedWaitUntil: - visible: "Email moved to Trash" - timeout: 15000 - takeScreenshot: actions-03-deleted - tapOn: text: "UNDO" diff --git a/.maestro/subflows/open-message.yaml b/.maestro/subflows/open-message.yaml index f87e9f0d..e61ad435 100644 --- a/.maestro/subflows/open-message.yaml +++ b/.maestro/subflows/open-message.yaml @@ -1,10 +1,31 @@ # From a message list: open the message whose row mentions SUBJECT. +# A row near the bottom can count as visible while the phone's tab bar +# covers it (the tap then opens another tab): on the phone, scroll it to the +# middle. The iPad's list is a column Maestro's scroll (in the middle of the +# screen) doesn't reach; its rows fit on screen. appId: org.bulwarkmail.mobile --- -- scrollUntilVisible: - element: ".*${SUBJECT}.*" - direction: DOWN - timeout: 30000 +- runFlow: + when: + true: ${DEVICE != 'tablet'} + commands: + - scrollUntilVisible: + element: ".*${SUBJECT}.*" + direction: DOWN + centerElement: true + visibilityPercentage: 100 + timeout: 30000 +- runFlow: + when: + true: ${DEVICE == 'tablet'} + commands: + - scrollUntilVisible: + element: ".*${SUBJECT}.*" + direction: DOWN + timeout: 30000 +# A tap while the list still moves lands on another row. +- waitForAnimationToEnd: + timeout: 5000 - tapOn: ".*${SUBJECT}.*" # The message toolbar's "more" button: "Reply All" shows on the phone, but # the iPad pane has a quick reply box instead for mail to one recipient. diff --git a/.maestro/subflows/settings-page.yaml b/.maestro/subflows/settings-page.yaml index 3f2e062b..68104a56 100644 --- a/.maestro/subflows/settings-page.yaml +++ b/.maestro/subflows/settings-page.yaml @@ -1,37 +1,33 @@ # Settings list: find the row ROW (regex on "Title, summary"), open it, # check PROOF shows, screenshot, and go back on a phone. # -# A row can count as visible while it is under the phone's tab bar or half -# off the iPad's screen, and the tap then misses. The phone scrolls it to the -# middle. The iPad's list is a left column that Maestro's scroll (always in -# the middle of the screen) doesn't reach, so it searches for the page (Q, -# a word of its title) instead, which puts the row near the top. +# Rows count as visible while the phone's tab bar or header covers them or +# while they hang half off the iPad's screen, and a tap then misses; the +# iPad's list is a left column Maestro's scroll (in the middle of the screen) +# doesn't reach. So search for the page (Q, a word of its title): the row +# then sits right under the search box. The account card (no Q) is always +# at the top. appId: org.bulwarkmail.mobile --- - runFlow: when: - true: ${DEVICE == 'tablet' && !!Q} + true: ${!!Q} commands: - - repeat: - while: + - tapOn: "Search settings" + - eraseText: 40 + - inputText: ${Q} + - waitForAnimationToEnd: + timeout: 3000 + # Now and then a typed character goes missing: type it again. + - runFlow: + when: notVisible: ${ROW} - times: 2 commands: - tapOn: "Search settings" - eraseText: 40 - inputText: ${Q} - waitForAnimationToEnd: timeout: 3000 -- runFlow: - when: - true: ${DEVICE != 'tablet'} - commands: - - scrollUntilVisible: - element: ${ROW} - direction: DOWN - centerElement: true - visibilityPercentage: 100 - timeout: 30000 # A tap while the list still coasts from the swipe only stops it. - waitForAnimationToEnd: timeout: 5000