e2e_tests/previous-work/authentik_test.py
2023-11-21 15:19:33 +01:00

23 lines
951 B
Python

from conftest import check_for, testuser, RECORDS
# playwright = sync_playwright().start()
# browser = playwright.chromium.launch(headless=False)
""" Test Changing Username in Authentik """
def test_authentik_change_username(user_session):
context, page = user_session
page.get_by_role("banner").get_by_role("link").nth(1).click()
page.get_by_placeholder(testuser["username"]).click()
page.get_by_placeholder(testuser["username"]).fill("renameduser")
page.get_by_role("button", name="Speichern").click()
check_for(page.get_by_role("heading", name="Not allowed to change username."))
context.tracing.stop(path=f"{RECORDS}/change_username.zip")
#""" Click all Apps """
#def test_dashboard(user_session):
# context, page = user_session
# for link in page.locator("ak-library-app").get_by_role("link").all():
# link.click()
# context.tracing.stop(path=f"{RECORDS}/test_dashboard.zip")
# context.close()
#