tests: functional: Add a convenience method to logout

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
Sunil Mohan Adapa authored and James Valleroy committed 2021-08-25 08:19:57 -04:00
1 parent 28030933dc
commit 5340cf3119
3 files changed
+13 -9

No files matched your search

@@ -158,7 +158,7 @@ def can_log_in(session_browser, username):
parsers.parse(
'I can log in as the user {username:w} with password {password:w}'))
def can_log_in_with_password(session_browser, username, password):
functional.visit(session_browser, '/plinth/accounts/logout/')
functional.logout(session_browser)
functional.login_with_account(session_browser, functional.base_url,
username, password)
assert len(session_browser.find_by_id('id_user_menu')) > 0