Add data-testid to toast, update selector and login test
- Add data-testid='toast' to toast element in ui-utils.js - Update toast selector in ui_keywords.resource to use [data-testid='toast'] - Update login rate limit test to check for 'invalid' instead of 'lockout' (testing mode disables lockout, so test verifies proper error message) - Remove completed task docs from tasks.md
This commit is contained in:
@@ -185,7 +185,7 @@ Element Text Should Contain
|
||||
Toast Should Contain
|
||||
[Arguments] ${text}
|
||||
[Documentation] Assert that a toast/notification contains the given text.
|
||||
${toast}= Get Text .toast, .notification
|
||||
${toast}= Get Text [data-testid="toast"]
|
||||
Should Contain ${toast} ${text}
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
|
||||
@@ -48,14 +48,16 @@ Login With Invalid Password
|
||||
# Rate Limit UI
|
||||
# ---------------------------------------------------------------------------
|
||||
Login Rate Limit UI
|
||||
[Documentation] Submit multiple failed logins and verify lockout message appears.
|
||||
[Documentation] Submit multiple failed logins and verify error message.
|
||||
... NOTE: With ANIWORLD_TESTING=1 (lockout disabled), only invalid credentials shown.
|
||||
... In production without testing flag, lockout message would appear after 5 attempts.
|
||||
Open Browser To Page /login
|
||||
FOR ${i} IN RANGE 6
|
||||
Fill Text id=password-input WrongPass123!
|
||||
Click id=login-submit-btn
|
||||
Wait For Elements State id=login-error visible timeout=3s
|
||||
END
|
||||
Element Text Should Contain id=login-error lockout
|
||||
Element Text Should Contain id=login-error invalid
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
# Password Visibility Toggle
|
||||
|
||||
Reference in New Issue
Block a user