freshyo/e2e/subflows/admin-login.yaml
2026-09-14 23:34:10 +05:30

25 lines
712 B
YAML

# Reusable admin login subflow.
#
# Only acts when the admin login screen is actually showing, so an existing
# staff session (launchApp without clearState) is left untouched.
#
# Env (from e2e/.env): ADMIN_NAME, ADMIN_PASSWORD
appId: in.freshyo.adminui
---
- runFlow:
when:
visible: "Admin Login"
commands:
- tapOn:
id: "login-name-input"
- inputText: ${ADMIN_NAME}
- tapOn:
id: "login-password-input"
- inputText: ${ADMIN_PASSWORD}
- hideKeyboard
- tapOn:
id: "login-button"
# The screen title disappears once we land on the dashboard.
- extendedWaitUntil:
notVisible: "Admin Login"
timeout: 60000