diff --git a/.github/workflows/build-pr.yml b/.github/workflows/build-pr.yml index 04d8db861dd..9871d27b04d 100644 --- a/.github/workflows/build-pr.yml +++ b/.github/workflows/build-pr.yml @@ -100,4 +100,9 @@ jobs: uses: ./.github/workflows/maestro-ios.yml needs: [e2e-build-ios] secrets: inherit - \ No newline at end of file + strategy: + matrix: + shard: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13] + fail-fast: false + with: + shard: ${{ matrix.shard }} \ No newline at end of file diff --git a/.github/workflows/maestro-android.yml b/.github/workflows/maestro-android.yml index 1d436dc8f74..20bcd599d85 100644 --- a/.github/workflows/maestro-android.yml +++ b/.github/workflows/maestro-android.yml @@ -127,4 +127,4 @@ jobs: with: name: maestro-video-${{ inputs.shard }} path: test_run_${{ inputs.shard }}_attempt_*.mp4 - retention-days: 7 + retention-days: 7 \ No newline at end of file diff --git a/.github/workflows/maestro-ios.yml b/.github/workflows/maestro-ios.yml index acda6f6d734..51eb55f5c1d 100644 --- a/.github/workflows/maestro-ios.yml +++ b/.github/workflows/maestro-ios.yml @@ -2,6 +2,10 @@ name: Maestro Tests on iOS on: workflow_call: + inputs: + shard: + required: true + type: string jobs: ios-test: @@ -85,20 +89,35 @@ jobs: xcrun simctl install $UDID "ios-simulator-app" - name: Run Tests - run: | - export MAESTRO_DRIVER_STARTUP_TIMEOUT=120000 - maestro test .maestro --format junit --output maestro-report.xml + id: maestro-tests + uses: nick-fields/retry@v3 + with: + max_attempts: 3 + timeout_minutes: 60 + command: | + SHARD=${{ inputs.shard }} + echo "Running shard: $SHARD" + export MAESTRO_DRIVER_STARTUP_TIMEOUT=120000 + + maestro test .maestro \ + --exclude-tags=util \ + --include-tags=test-$SHARD \ + --exclude-tags=android-only \ + --format junit \ + --output maestro-report.xml - - name: Upload Test Report + - name: Maestro Test Report if: always() uses: actions/upload-artifact@v4 with: - name: Test Report + name: Test Report - Shard ${{ inputs.shard }} path: maestro-report.xml + retention-days: 28 - - name: Upload Maestro Logs + - name: iOS Maestro Logs if: always() uses: actions/upload-artifact@v4 with: - name: iOS Maestro Logs - path: ~/.maestro/tests/ \ No newline at end of file + name: iOS Maestro Logs - Shard ${{ inputs.shard }} + path: ~/.maestro/tests/ + retention-days: 28 \ No newline at end of file diff --git a/.maestro/helpers/erase-text.yaml b/.maestro/helpers/erase-text.yaml index e32799a665b..616f8863b71 100644 --- a/.maestro/helpers/erase-text.yaml +++ b/.maestro/helpers/erase-text.yaml @@ -4,8 +4,18 @@ tags: - 'util' --- -- longPressOn: - id: ${id} +- runFlow: + when: + true: ${id != null} + commands: + - longPressOn: + id: ${id} +- runFlow: + when: + true: ${text != null} + commands: + - doubleTapOn: + text: .*${text}.* - runFlow: when: visible: @@ -13,3 +23,9 @@ tags: commands: - tapOn: Select All - eraseText: 1 +- runFlow: + when: + notVisible: + text: 'Select All' + commands: + - eraseText: 100 diff --git a/.maestro/helpers/hide-keyboard.yaml b/.maestro/helpers/hide-keyboard.yaml new file mode 100644 index 00000000000..e85077c5f7c --- /dev/null +++ b/.maestro/helpers/hide-keyboard.yaml @@ -0,0 +1,17 @@ +appId: chat.rocket.reactnative +name: Hide Keyboard +tags: + - 'util' + +--- +- runFlow: + when: + platform: android + commands: + - hideKeyboard +- runFlow: + when: + platform: iOS + commands: + - tapOn: + point: 1%,20% diff --git a/.maestro/helpers/launch-app.yaml b/.maestro/helpers/launch-app.yaml index 9362034d1f3..fa6607fa60a 100644 --- a/.maestro/helpers/launch-app.yaml +++ b/.maestro/helpers/launch-app.yaml @@ -16,6 +16,7 @@ tags: - runFlow: when: visible: '.*Pixel Launcher.*' + platform: Android commands: - tapOn: 'Close App' - assertVisible: 'Add workspace' diff --git a/.maestro/helpers/login-with-deeplink.yaml b/.maestro/helpers/login-with-deeplink.yaml index 32f7ab8d564..6c592e17a7d 100644 --- a/.maestro/helpers/login-with-deeplink.yaml +++ b/.maestro/helpers/login-with-deeplink.yaml @@ -4,13 +4,8 @@ tags: - 'util' --- -- runFlow: - when: - true: CLEAR_STATE - platform: android - commands: - - clearState - - stopApp: chat.rocket.reactnative +- clearState +- stopApp: chat.rocket.reactnative - evalScript: ${output.login = output.utils.login(USERNAME, PASSWORD)} - runFlow: file: 'open-deeplink.yaml' @@ -36,6 +31,13 @@ tags: - assertNotVisible: text: '.*Allow.*' optional: true +- runFlow: + when: + visible: '.*Would like to send you notifications.*' + platform: iOS + commands: + - tapOn: + point: 65%,60% - extendedWaitUntil: visible: id: 'rooms-list-view' diff --git a/.maestro/helpers/logout.yaml b/.maestro/helpers/logout.yaml index 7ab568d512a..e58688f6463 100644 --- a/.maestro/helpers/logout.yaml +++ b/.maestro/helpers/logout.yaml @@ -43,6 +43,15 @@ tags: - tapOn: id: 'settings-logout' +- extendedWaitUntil: + visible: + text: '.*You will be logged out of this application.*' + timeout: 60000 + +- assertVisible: + text: Logout + index: 0 + - runFlow: when: platform: Android @@ -60,10 +69,9 @@ tags: platform: iOS commands: - tapOn: - text: Logout - index: 1 + point: '65%,56%' - extendedWaitUntil: visible: id: 'new-server-view' - timeout: 60000 + timeout: 5000 diff --git a/.maestro/helpers/navigate-to-room.yaml b/.maestro/helpers/navigate-to-room.yaml index 9fdb085972e..6b71c565378 100644 --- a/.maestro/helpers/navigate-to-room.yaml +++ b/.maestro/helpers/navigate-to-room.yaml @@ -4,9 +4,11 @@ tags: - 'util' --- +- waitForAnimationToEnd - scrollUntilVisible: element: id: 'rooms-list-view-item-${ROOM}' +- waitForAnimationToEnd - tapOn: id: 'rooms-list-view-item-${ROOM}' - extendedWaitUntil: diff --git a/.maestro/helpers/open-deeplink.yaml b/.maestro/helpers/open-deeplink.yaml index 7bd6407764d..432fc3ed2b3 100644 --- a/.maestro/helpers/open-deeplink.yaml +++ b/.maestro/helpers/open-deeplink.yaml @@ -11,4 +11,11 @@ tags: visible: '.*Open in.*' platform: iOS commands: - - tapOn: Open + - tapOn: + text: Open + index: 0 + optional: true + - tapOn: + text: Open + index: 1 + optional: true diff --git a/.maestro/tests/assorted/accessibility-and-appearance.yaml b/.maestro/tests/assorted/accessibility-and-appearance.yaml index 65ae25d7994..7c91cdc792b 100644 --- a/.maestro/tests/assorted/accessibility-and-appearance.yaml +++ b/.maestro/tests/assorted/accessibility-and-appearance.yaml @@ -6,6 +6,7 @@ onFlowComplete: - evalScript: ${output.utils.deleteCreatedUsers()} tags: - test-5 + - android-only --- - evalScript: ${output.user = output.utils.createUser()} diff --git a/.maestro/tests/assorted/broadcast.yaml b/.maestro/tests/assorted/broadcast.yaml index e824ffc5084..1ee8df14453 100644 --- a/.maestro/tests/assorted/broadcast.yaml +++ b/.maestro/tests/assorted/broadcast.yaml @@ -132,7 +132,7 @@ tags: # should have the message created earlier - assertVisible: - text: 'message' + id: 'message-content-message' # should tap on reply button and navigate to direct room - assertVisible: diff --git a/.maestro/tests/assorted/profile.yaml b/.maestro/tests/assorted/profile.yaml index c9b082e2447..43f673d16ee 100644 --- a/.maestro/tests/assorted/profile.yaml +++ b/.maestro/tests/assorted/profile.yaml @@ -9,7 +9,6 @@ tags: --- - evalScript: ${output.user = output.utils.createUser()} - - runFlow: file: '../../helpers/login-with-deeplink.yaml' env: @@ -103,6 +102,7 @@ tags: element: id: 'profile-view-submit' timeout: 60000 + centerElement: true - tapOn: id: 'profile-view-submit' @@ -127,6 +127,7 @@ tags: element: id: 'profile-view-submit' timeout: 60000 + centerElement: true - tapOn: id: 'profile-view-submit' @@ -146,12 +147,10 @@ tags: env: id: 'profile-view-email' - inputText: mobile+profileChangesNew${output.random()}@rocket.chat -- tapOn: - text: '.*Email.*' - index: 0 - scrollUntilVisible: element: id: 'profile-view-submit' + centerElement: true timeout: 60000 - tapOn: id: 'profile-view-submit' diff --git a/.maestro/tests/room/create-dm-group.yaml b/.maestro/tests/room/create-dm-group.yaml index 2e4a13fbaed..e24fda7f561 100644 --- a/.maestro/tests/room/create-dm-group.yaml +++ b/.maestro/tests/room/create-dm-group.yaml @@ -40,10 +40,10 @@ tags: # should navigate to create DM - extendedWaitUntil: visible: - text: '.*Direct message.*' + id: 'new-message-view-create-direct-message' timeout: 60000 - tapOn: - text: '.*Direct message.*' + id: 'new-message-view-create-direct-message' # should add users - extendedWaitUntil: diff --git a/.maestro/tests/room/discussion.yaml b/.maestro/tests/room/discussion.yaml index f65acb1b56a..dcfe68b6789 100644 --- a/.maestro/tests/room/discussion.yaml +++ b/.maestro/tests/room/discussion.yaml @@ -43,7 +43,8 @@ tags: visible: id: 'create-discussion-view' timeout: 60000 -- tapOn: 'Select a channel' +- tapOn: + id: 'create-discussion-select-channel' - extendedWaitUntil: visible: id: 'action-sheet' @@ -141,7 +142,7 @@ tags: timeout: 60000 - extendedWaitUntil: visible: - text: ${output.room.name} + text: .*${output.room.name}.* timeout: 60000 - tapOn: id: multi-select-discussion-name @@ -313,10 +314,10 @@ tags: # should navigate to discussion - extendedWaitUntil: visible: - text: .*${output.discussionFromNewMessage}.* + id: 'discussions-view-${output.discussionFromNewMessage}' timeout: 60000 - tapOn: - text: .*${output.discussionFromNewMessage}.* + id: 'discussions-view-${output.discussionFromNewMessage}' - extendedWaitUntil: visible: id: 'room-view-title-${output.discussionFromNewMessage}' diff --git a/.maestro/tests/room/ignoreuser.yaml b/.maestro/tests/room/ignoreuser.yaml index a07ff2184dc..9eaff66e266 100644 --- a/.maestro/tests/room/ignoreuser.yaml +++ b/.maestro/tests/room/ignoreuser.yaml @@ -86,22 +86,19 @@ tags: - evalScript: ${output.utils.sendMessage(output.otherUser.username, output.otherUser.password, output.room._id, 'message-02')} - extendedWaitUntil: visible: - text: ${output.otherUser.username} - index: 0 + id: 'username-header-${output.otherUser.username}' timeout: 60000 -- tapOn: ${output.otherUser.username} +- tapOn: + id: 'username-header-${output.otherUser.username}' + retryTapIfNoChange: true - extendedWaitUntil: visible: text: 'Ignore' - childOf: - id: room-info-view-ignore timeout: 60000 - tapOn: 'Ignore' - extendedWaitUntil: visible: text: 'Unignore' - childOf: - id: room-info-view-ignore timeout: 60000 - runFlow: '../../helpers/go-back.yaml' @@ -115,35 +112,44 @@ tags: text: .*Message ignored. Tap to display it.* index: 0 timeout: 60000 -- tapOn: .*Message ignored. Tap to display it.* -- extendedWaitUntil: - visible: - text: ${output.otherUser.username} - index: 0 - timeout: 60000 +- tapOn: + text: .*Message ignored. Tap to display it.* + index: 0 - extendedWaitUntil: visible: - text: 'message-02' - index: 0 + id: 'username-header-${output.otherUser.username}' timeout: 60000 +- runFlow: + when: + platform: android + commands: + - extendedWaitUntil: + visible: + id: 'message-content-message-01' + timeout: 60000 +- runFlow: + when: + platform: iOS + commands: + - extendedWaitUntil: + visible: + id: 'message-content-message-02' + timeout: 60000 - extendedWaitUntil: visible: - text: ${output.otherUser.username} - index: 0 + id: 'username-header-${output.otherUser.username}' timeout: 60000 -- tapOn: ${output.otherUser.username} +- tapOn: + id: 'username-header-${output.otherUser.username}' + retryTapIfNoChange: true - extendedWaitUntil: visible: text: 'Unignore' - childOf: - id: room-info-view-ignore timeout: 60000 - tapOn: 'Unignore' - extendedWaitUntil: visible: text: 'Ignore' - childOf: - id: room-info-view-ignore timeout: 60000 - runFlow: '../../helpers/go-back.yaml' - runFlow: @@ -152,7 +158,7 @@ tags: ROOM: ${output.room.name} - extendedWaitUntil: visible: - text: 'message-02' + id: 'message-content-message-02' index: 0 timeout: 60000 @@ -168,8 +174,6 @@ tags: - extendedWaitUntil: visible: text: 'Report' - childOf: - id: room-info-view-warning timeout: 60000 - tapOn: 'Report' - extendedWaitUntil: @@ -216,8 +220,6 @@ tags: - extendedWaitUntil: visible: text: 'Report' - childOf: - id: room-info-view-warning - tapOn: 'Report' - extendedWaitUntil: visible: diff --git a/.maestro/tests/room/jump-to-message.yaml b/.maestro/tests/room/jump-to-message.yaml index 7b11cf46b82..bfe651f52ca 100644 --- a/.maestro/tests/room/jump-to-message.yaml +++ b/.maestro/tests/room/jump-to-message.yaml @@ -25,10 +25,11 @@ tags: timeout: 60000 - extendedWaitUntil: visible: - text: '.*Quote first message.*' + id: '.*Quote first message.*' timeout: 60000 - longPressOn: - text: '.*Quote first message.*' + id: '.*Quote first message.*' + retryTapIfNoChange: true - extendedWaitUntil: visible: text: 'Jump to message' @@ -100,7 +101,8 @@ tags: timeout: 60000 - tapOn: id: 'search-message-view-input' -- inputText: '30' +- inputText: '3' +- inputText: '0' - extendedWaitUntil: visible: id: 'message-content-30' @@ -153,7 +155,8 @@ tags: direction: DOWN timeout: 60000 - tapOn: - text: '.*Load newer.*' + text: 'Load newer' + retryTapIfNoChange: true - extendedWaitUntil: visible: id: 'message-content-104' @@ -163,7 +166,8 @@ tags: text: '.*Load newer.*' timeout: 60000 - tapOn: - text: '.*Load newer.*' + text: 'Load newer' + retryTapIfNoChange: true - extendedWaitUntil: visible: id: 'message-content-154' @@ -173,7 +177,8 @@ tags: text: '.*Load newer.*' timeout: 60000 - tapOn: - text: '.*Load newer.*' + text: 'Load newer' + retryTapIfNoChange: true - extendedWaitUntil: visible: id: 'message-content-202' @@ -192,6 +197,7 @@ tags: timeout: 60000 - longPressOn: text: .*Go to jumping-thread's thread.* + retryTapIfNoChange: true - extendedWaitUntil: visible: text: 'Jump to message' @@ -215,7 +221,8 @@ tags: text: '.*thread message sent to main room.*' timeout: 60000 - tapOn: - text: '.*thread message sent to main room.*' + text: 'thread message sent to main room' + retryTapIfNoChange: true - runFlow: file: './utils/expect-thread-messages.yaml' env: @@ -233,7 +240,7 @@ tags: text: '.*quoted.*' timeout: 60000 - longPressOn: - text: '.*quoted.*' + text: 'quoted' - extendedWaitUntil: visible: text: 'Jump to message' diff --git a/.maestro/tests/room/room-actions.yaml b/.maestro/tests/room/room-actions.yaml index e83bb7fc7d9..1073f819ea9 100644 --- a/.maestro/tests/room/room-actions.yaml +++ b/.maestro/tests/room/room-actions.yaml @@ -127,6 +127,10 @@ tags: timeout: 60000 - tapOn: text: 'Star' +- extendedWaitUntil: + notVisible: + text: '.*Message Starred.*' + timeout: 60000 - tapOn: id: 'room-header' - extendedWaitUntil: @@ -134,7 +138,8 @@ tags: id: 'room-actions-view' timeout: 60000 - tapOn: - text: 'Starred' + id: 'room-actions-starred' + retryTapIfNoChange: true - extendedWaitUntil: visible: id: starred-messages-view @@ -172,6 +177,10 @@ tags: timeout: 60000 - tapOn: text: 'Unstar' +- extendedWaitUntil: + notVisible: + text: '.*Message Unstarred.*' + timeout: 60000 - tapOn: id: 'room-header' - extendedWaitUntil: @@ -179,7 +188,8 @@ tags: id: 'room-actions-view' timeout: 60000 - tapOn: - text: 'Starred' + id: 'room-actions-starred' + retryTapIfNoChange: true - extendedWaitUntil: visible: id: starred-messages-view diff --git a/.maestro/tests/room/room-info.yaml b/.maestro/tests/room/room-info.yaml index 68fd16c3381..c1ba9dae806 100644 --- a/.maestro/tests/room/room-info.yaml +++ b/.maestro/tests/room/room-info.yaml @@ -141,15 +141,19 @@ tags: timeout: 60000 # should reset form -- scrollUntilVisible: - element: +- tapOn: + id: custom-header-back +- tapOn: + id: room-info-view-edit-button +- extendedWaitUntil: + visible: id: 'room-info-edit-view-name' - direction: UP timeout: 60000 - tapOn: id: room-info-edit-view-name - eraseText - inputText: abc +- runFlow: '../../helpers/hide-keyboard.yaml' - scrollUntilVisible: element: id: 'room-info-edit-view-topic' @@ -157,6 +161,7 @@ tags: - tapOn: id: 'room-info-edit-view-topic' - inputText: abc +- runFlow: '../../helpers/hide-keyboard.yaml' - scrollUntilVisible: element: id: 'room-info-edit-view-announcement' @@ -164,6 +169,7 @@ tags: - tapOn: id: 'room-info-edit-view-announcement' - inputText: abc +- runFlow: '../../helpers/hide-keyboard.yaml' - scrollUntilVisible: element: id: 'room-info-edit-view-description' @@ -171,6 +177,7 @@ tags: - tapOn: id: 'room-info-edit-view-description' - inputText: abc +- runFlow: '../../helpers/hide-keyboard.yaml' - scrollUntilVisible: element: id: 'room-info-edit-view-password' @@ -178,17 +185,19 @@ tags: - tapOn: id: 'room-info-edit-view-password' - inputText: abc -- pressKey: Enter +- runFlow: '../../helpers/hide-keyboard.yaml' - scrollUntilVisible: element: id: 'room-info-edit-view-t' timeout: 60000 + centerElement: true - tapOn: id: 'room-info-edit-view-t' - scrollUntilVisible: element: id: 'room-info-edit-view-ro' timeout: 60000 + centerElement: true - tapOn: id: 'room-info-edit-view-ro' - scrollUntilVisible: @@ -206,13 +215,13 @@ tags: - scrollUntilVisible: element: - id: 'room-info-edit-view-name' + id: 'avatar-edit-button' + timeout: 60000 direction: UP +- scrollUntilVisible: + element: + text: '.*${output.room.name}.*' timeout: 60000 -- assertVisible: - text: '.*${output.room.name}.*' - childOf: - id: 'room-info-edit-view-name' - scrollUntilVisible: element: id: 'room-info-edit-view-topic' @@ -269,12 +278,11 @@ tags: id: 'room-info-edit-view-react-when-ro' # should change room name +- tapOn: + id: custom-header-back +- tapOn: + id: room-info-view-edit-button - evalScript: ${output.newroomname = output.room.name + 'new'} -- scrollUntilVisible: - element: - id: 'room-info-edit-view-name' - direction: UP - timeout: 60000 - tapOn: id: 'room-info-edit-view-name' - runFlow: @@ -289,10 +297,14 @@ tags: timeout: 60000 - tapOn: id: 'room-info-edit-view-submit' -- extendedWaitUntil: - visible: - text: '.*Settings succesfully changed.*' - timeout: 60000 +- runFlow: + when: + platform: android + commands: + - extendedWaitUntil: + visible: + text: '.*Settings succesfully changed.*' + timeout: 60000 - tapOn: id: custom-header-back - extendedWaitUntil: @@ -316,6 +328,7 @@ tags: - tapOn: id: 'room-info-edit-view-topic' - inputText: 'new topic' +- runFlow: '../../helpers/hide-keyboard.yaml' - scrollUntilVisible: element: id: 'room-info-edit-view-announcement' @@ -323,6 +336,7 @@ tags: - tapOn: id: 'room-info-edit-view-announcement' - inputText: 'new announcement' +- runFlow: '../../helpers/hide-keyboard.yaml' - scrollUntilVisible: element: id: 'room-info-edit-view-description' @@ -330,17 +344,21 @@ tags: - tapOn: id: 'room-info-edit-view-description' - inputText: 'new description' -- pressKey: Enter +- runFlow: '../../helpers/hide-keyboard.yaml' - scrollUntilVisible: element: id: 'room-info-edit-view-submit' timeout: 60000 - tapOn: id: 'room-info-edit-view-submit' -- extendedWaitUntil: - visible: - text: '.*Settings succesfully changed.*' - timeout: 60000 +- runFlow: + when: + platform: android + commands: + - extendedWaitUntil: + visible: + text: '.*Settings succesfully changed.*' + timeout: 60000 - tapOn: id: custom-header-back - extendedWaitUntil: @@ -373,10 +391,14 @@ tags: timeout: 60000 - tapOn: id: 'room-info-edit-view-submit' -- extendedWaitUntil: - visible: - text: '.*Settings succesfully changed.*' - timeout: 60000 +- runFlow: + when: + platform: android + commands: + - extendedWaitUntil: + visible: + text: '.*Settings succesfully changed.*' + timeout: 60000 # should archive room - scrollUntilVisible: diff --git a/.maestro/tests/room/room.yaml b/.maestro/tests/room/room.yaml index 9ca8daf8625..c45bf5822a3 100644 --- a/.maestro/tests/room/room.yaml +++ b/.maestro/tests/room/room.yaml @@ -82,20 +82,20 @@ tags: visible: id: message-composer-input timeout: 60000 -- inputText: '#general' +- inputText: '#translation-test' - extendedWaitUntil: visible: - id: 'autocomplete-item-general' + id: 'autocomplete-item-translation-test' timeout: 60000 - tapOn: - id: 'autocomplete-item-general' + id: 'autocomplete-item-translation-test' - extendedWaitUntil: visible: - text: '#general ' + text: '#translation-test ' timeout: 60000 - extendedWaitUntil: notVisible: - id: 'autocomplete-item-general' + id: 'autocomplete-item-translation-test' timeout: 60000 - tapOn: id: message-composer-input @@ -107,7 +107,7 @@ tags: text: .*${output.randomMessage}.* timeout: 60000 - longPressOn: - text: .*${output.randomMessage}.* + id: 'message-content-${output.randomMessage}' - waitForAnimationToEnd - extendedWaitUntil: visible: @@ -142,7 +142,7 @@ tags: text: .*${output.randomMessage}.* timeout: 60000 - longPressOn: - text: .*${output.randomMessage}.* + id: 'message-content-${output.randomMessage}' - waitForAnimationToEnd - extendedWaitUntil: visible: @@ -191,7 +191,7 @@ tags: text: .*${output.randomMessage}.* timeout: 60000 - longPressOn: - text: .*${output.randomMessage}.* + id: 'message-content-${output.randomMessage}' - waitForAnimationToEnd - extendedWaitUntil: visible: @@ -317,7 +317,7 @@ tags: text: '.*edit.*' timeout: 60000 - longPressOn: - text: '.*edit.*' + id: 'message-content-edit' - extendedWaitUntil: visible: id: action-sheet @@ -355,7 +355,7 @@ tags: text: '.*quote.*' timeout: 60000 - longPressOn: - text: '.*quote.*' + id: 'message-content-quote' - extendedWaitUntil: visible: id: action-sheet @@ -407,7 +407,7 @@ tags: text: '.*message to delete.*' timeout: 60000 - longPressOn: - text: '.*message to delete.*' + id: 'message-content-message to delete' - extendedWaitUntil: visible: id: action-sheet @@ -463,7 +463,7 @@ tags: id: 'room-view-join-button' timeout: 60000 - longPressOn: - text: .*${output.originalMessage}.* + id: 'message-content-${output.originalMessage}' - extendedWaitUntil: visible: id: action-sheet @@ -578,7 +578,7 @@ tags: text: .*${output.draftMessage}.* timeout: 60000 - longPressOn: - text: .*${output.originalMessage}.* + id: 'message-content-${output.originalMessage}' - extendedWaitUntil: visible: id: action-sheet diff --git a/.maestro/tests/room/share-message.yaml b/.maestro/tests/room/share-message.yaml index 3bf9b686111..4bbf18fff3e 100644 --- a/.maestro/tests/room/share-message.yaml +++ b/.maestro/tests/room/share-message.yaml @@ -40,10 +40,10 @@ tags: # should open the action sheet and tap Forward - extendedWaitUntil: visible: - text: 'Hello room' - index: 0 + id: 'message-content-Hello room' timeout: 60000 -- longPressOn: 'Hello room' +- longPressOn: + id: 'message-content-Hello room' - extendedWaitUntil: visible: id: 'action-sheet' @@ -59,7 +59,8 @@ tags: visible: id: 'forward-message-view' timeout: 60000 -- tapOn: 'Select' +- tapOn: + id: 'select-person-or-channel' - extendedWaitUntil: visible: id: 'multi-select-search' @@ -75,7 +76,8 @@ tags: - tapOn: id: multi-select-item-${output.otherUser.username.toLowerCase()} - swipe: - id: 'action-sheet-handle' + from: + id: 'action-sheet-handle' direction: DOWN - extendedWaitUntil: notVisible: @@ -100,7 +102,7 @@ tags: ROOM: ${output.otherUser.username} - extendedWaitUntil: visible: - text: 'Hello user' + id: 'message-content-Hello user' timeout: 60000 - extendedWaitUntil: visible: diff --git a/.maestro/tests/room/threads.yaml b/.maestro/tests/room/threads.yaml index f38f88a3980..c67374ca194 100644 --- a/.maestro/tests/room/threads.yaml +++ b/.maestro/tests/room/threads.yaml @@ -165,7 +165,7 @@ tags: timeout: 5000 - extendedWaitUntil: visible: - id: 'message-preview-sendToChannel' + text: '.*sendToChannel.*' timeout: 5000 # should navigate to thread from thread name diff --git a/.maestro/tests/room/utils/clear-cache.yaml b/.maestro/tests/room/utils/clear-cache.yaml index 599f4ecb7b6..313ac3f1e1c 100644 --- a/.maestro/tests/room/utils/clear-cache.yaml +++ b/.maestro/tests/room/utils/clear-cache.yaml @@ -16,12 +16,16 @@ tags: timeout: 60000 - tapOn: id: 'rooms-list-view-sidebar' +- waitForAnimationToEnd: + timeout: 60000 - extendedWaitUntil: visible: id: 'sidebar-settings' timeout: 60000 - tapOn: id: 'sidebar-settings' +- waitForAnimationToEnd: + timeout: 60000 - extendedWaitUntil: visible: id: 'settings-view-clear-cache' diff --git a/.maestro/tests/teams/team.yaml b/.maestro/tests/teams/team.yaml index a64e6d02c1f..67ba897ffb1 100644 --- a/.maestro/tests/teams/team.yaml +++ b/.maestro/tests/teams/team.yaml @@ -320,7 +320,7 @@ tags: - extendedWaitUntil: visible: id: select-users-view-item-${output.secondUser.username} - timeout: + timeout: 60000 - tapOn: id: select-users-view-item-${output.secondUser.username} - extendedWaitUntil: diff --git a/app/views/CreateDiscussionView/SelectChannel.tsx b/app/views/CreateDiscussionView/SelectChannel.tsx index 1b840b54b7c..f1a703b0b08 100644 --- a/app/views/CreateDiscussionView/SelectChannel.tsx +++ b/app/views/CreateDiscussionView/SelectChannel.tsx @@ -72,6 +72,7 @@ const SelectChannel = ({ }))} onClose={() => getChannels('')} placeholder={{ text: I18n.t('Select_a_Channel') }} + testID='create-discussion-select-channel' /> ); diff --git a/app/views/ForwardMessageView/SelectPersonOrChannel.tsx b/app/views/ForwardMessageView/SelectPersonOrChannel.tsx index 411550d0e28..71625cfcda8 100644 --- a/app/views/ForwardMessageView/SelectPersonOrChannel.tsx +++ b/app/views/ForwardMessageView/SelectPersonOrChannel.tsx @@ -68,6 +68,7 @@ const SelectPersonOrChannel = ({ placeholder={{ text: `${I18n.t('Select')}` }} context={BlockContext.FORM} multiselect + testID='select-person-or-channel' /> );