Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ui-flows/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ To be able to run the flows, you need to [install the CLI tools](https://docs.ma

Ensure a device or emulator is running and execute:

- `maestro test ui-flows/validate/ini_withh_demo_account.yml`
- `maestro test ui-flows/validate/init_with_demo_account.yml`
- `maestro test ui-flows/validate/compose_simple_message.yml`

The following commands are limited to the exact emulator configuration mentioned above:
Expand Down
19 changes: 12 additions & 7 deletions ui-flows/shared/add_contact.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,30 @@
# NAME: Alice
# FIRST_NAME: Alice

appId: net.thunderbird.android.debug
appId: net.thunderbird.android.beta
---

## Add contact
- tapOn:
id: "net.thunderbird.android.debug:id/menu_add_contact"
index: ${INDEX}
- tapOn: ${FIRST_NAME}
id: "net.thunderbird.android.beta:id/menu_add_contact"
# index: ${INDEX}
#- tapOn: ${FIRST_NAME}

## Create new contact
- tapOn:
id: "com.android.contacts:id/cliv_name_textview"

## Add 'from Contacts' to Name
- runFlow:
when:
visible:
id: "com.android.contacts:id/editor_menu_save_button"
commands:
- inputText: " from Contacts"
### Save
## Save
- tapOn:
id: "com.android.contacts:id/editor_menu_save_button"

### Exit
- tapOn:
id: "com.android.systemui:id/back"
#- tapOn:
# id: "com.android.systemui:id/back"
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
appId: net.thunderbird.android.debug
appId: net.thunderbird.android.beta
#maestro test ui-flows/shared/change_display_settings_show_contact_names.yml
---

## Open settings
Expand All @@ -12,10 +13,14 @@ appId: net.thunderbird.android.debug
direction: DOWN
timeout: 10000

### Enable "Show contact names"
### Check if show contact names is enabled
#to be updated

## Enable "Show contact names"
- tapOn:
id: "android:id/title"
text: "Show contact names"
checked: "false"

### Close settings
- runFlow: close_display_settings.yml
4 changes: 2 additions & 2 deletions ui-flows/shared/close_display_settings.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
appId: net.thunderbird.android.debug
appId: net.thunderbird.android.beta
---

- tapOn: "Navigate up"
- tapOn: "Navigate up"
- tapOn: "Navigate up"
- swipe:
direction: LEFT
duration: 200
# duration: 50
10 changes: 10 additions & 0 deletions ui-flows/shared/close_message_details.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
appId: net.thunderbird.android.beta
---

- assertVisible:
id: "net.thunderbird.android.beta:id/message_details_list"
- swipe:
from:
id: "net.thunderbird.android.beta:id/message_details_list"
direction: DOWN
duration: 200
12 changes: 9 additions & 3 deletions ui-flows/shared/create_demo_account.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# ACCOUNT_NAME: "Demo Account"
# DISPLAY_NAME: "Demo User"

appId: net.thunderbird.android.debug
appId: net.thunderbird.android.beta
---
## Auto-discovery screen
- waitForAnimationToEnd:
Expand All @@ -17,11 +17,17 @@ appId: net.thunderbird.android.debug
- tapOn:
id: "account_setup_next_button"

## Wait for auto-discovery to complete and enter password
## Configuration not found - tap next
- tapOn:
id: "account_setup_next_button"

## Wait for auto-discovery to complete
- waitForAnimationToEnd:
timeout: 500

## Enter the password --> the test will fail because the Server is '.servername.com' instead of 'servername.com'
- tapOn:
id: "account_setup_password_input"
text: "Password"
- waitForAnimationToEnd:
timeout: 500
- inputText: "password"
Expand Down
11 changes: 11 additions & 0 deletions ui-flows/shared/grant_google_account_access.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
appId: com.android.chrome
---

## Grant access to your Google Account
- scrollUntilVisible:
element:
id: "submit_approve_access"
direction: DOWN

- tapOn:
id: "submit_approve_access"
35 changes: 35 additions & 0 deletions ui-flows/shared/onboard_with_configured_account.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
appId: net.thunderbird.android.beta
---
- launchApp:
clearState: true

## Welcome screen
- tapOn:
id: "onboarding_welcome_start_button"

## Already using Thunderbird screen
- waitForAnimationToEnd:
timeout: 800
- tapOn:
id: "onboarding_migration_new_account_button"

- runFlow:
file: sign_in_with_configured_account.yml
env:
EMAIL_ADDRESS: "[email protected]"
ACCOUNT_NAME: "Demo Account"
DISPLAY_NAME: "Demo User"

# Permissions
- waitForAnimationToEnd:
timeout: 800
- runFlow:
when:
visible:
id: "onboarding_permissions_next_button"
commands:
- tapOn:
id: "onboarding_permissions_next_button"

- waitForAnimationToEnd:
timeout: 500
4 changes: 2 additions & 2 deletions ui-flows/shared/onboard_with_demo_account.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
appId: net.thunderbird.android.debug
appId: net.thunderbird.android.beta
---
- launchApp:
clearState: true
Expand All @@ -16,7 +16,7 @@ appId: net.thunderbird.android.debug
- runFlow:
file: create_demo_account.yml
env:
EMAIL_ADDRESS: "demo@example.com"
EMAIL_ADDRESS: "demotest@example.com"
ACCOUNT_NAME: "Demo Account"
DISPLAY_NAME: "Demo User"

Expand Down
27 changes: 23 additions & 4 deletions ui-flows/shared/open_display_settings.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
appId: net.thunderbird.android.debug
appId: net.thunderbird.android.beta
#maestro test ui-flows/shared/open_display_settings.yml
---

## Open drawer
- tapOn: "Navigate up"

### Open settings
- tapOn:
id: "net.thunderbird.android.debug:id/material_drawer_name"
index: 9
text: "Settings"

### Open general settings
- tapOn:
id: "net.thunderbird.android.debug:id/text"
id: "net.thunderbird.android.beta:id/text"
index: 0
text: "General settings"

Expand All @@ -20,3 +20,22 @@ appId: net.thunderbird.android.debug
id: "android:id/title"
index: 0
text: "Display"


### Open drawer
#- tapOn:
# point: 10%,10%
#
#### Open settings
#- tapOn:
# point: 10%,90%
#
#### Open general settings
#- tapOn:
# id: "net.thunderbird.android.beta:id/text"
# index: 0
#
#### Open display settings
#- tapOn:
# id: "android:id/title"
# index: 0
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is a lot of yaml commented out throughout these files. Is that expected?

13 changes: 5 additions & 8 deletions ui-flows/shared/open_message_details.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
appId: net.thunderbird.android.debug
appId: net.thunderbird.android.beta
---

- tapOn:
id: "net.thunderbird.android.debug:id/participants_container"
id: "net.thunderbird.android.beta:id/participants_container"
- swipe:
from:
id: "net.thunderbird.android.debug:id/message_details_list"
id: "net.thunderbird.android.beta:id/message_details_list"
direction: UP
- swipe:
from:
id: "net.thunderbird.android.debug:id/message_details_list"
direction: DOWN
duration: 200


5 changes: 2 additions & 3 deletions ui-flows/shared/remove_contact.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,12 @@
# env:
# NAME: Alice

appId: net.thunderbird.android.debug
appId: net.thunderbird.android.beta
---

## Open contact
- tapOn:
id: "net.thunderbird.android.debug:id/name"
text: ${NAME}
id: "net.thunderbird.android.beta:id/participants_container"

## Delete contact
- tapOn: "More options"
Expand Down
55 changes: 55 additions & 0 deletions ui-flows/shared/sign_in_with_configured_account.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# use env to provide properties:
# env:
# EMAIL_ADDRESS: "[email protected]"
# ACCOUNT_NAME: "Demo Account"
# DISPLAY_NAME: "Demo User"

appId: net.thunderbird.android.beta
---
## Auto-discovery screen
- waitForAnimationToEnd:
timeout: 500
- tapOn:
id: "account_setup_email_address_input"
- waitForAnimationToEnd:
timeout: 800
- inputText: ${EMAIL_ADDRESS}
- tapOn:
id: "account_setup_next_button"

## Configuration was found - sign in with google
- tapOn:
text: "Sign in with Google"

## Grant access to your Google Account
- runFlow:
file: ../shared/grant_google_account_access.yml

## Wait for auto-discovery to complete
- waitForAnimationToEnd:
timeout: 1500

## Display options
- longPressOn:
id: "account_setup_display_options_account_name_input"
- runFlow:
label: Select All
when:
visible: 'Select All'
commands:
- tapOn: 'Select All'
- eraseText: 1
- inputText: ${ACCOUNT_NAME}
- tapOn:
id: "account_setup_display_options_display_name_input"
- inputText: ${DISPLAY_NAME}
- tapOn:
id: "account_setup_next_button"

## Sync options
- waitForAnimationToEnd:
timeout: 500
- tapOn:
id: "account_setup_next_button"
- waitForAnimationToEnd:
timeout: 500
Loading
Loading