0
0
Fork 0
mirror of https://github.com/nextcloud/docker.git synced 2025-03-14 18:35:08 +01:00

Fixed scirpts

This commit is contained in:
Danilo Ješić 2023-06-09 14:41:11 +02:00
parent ab4b43c93b
commit b7b5729532
2 changed files with 5 additions and 8 deletions

View file

@ -9,7 +9,7 @@ def main():
)
page = browser.new_page()
page.goto('http://nc/')
page.set_default_timeout(120_000)
page.set_default_timeout(180_000)
# 1. Create User
page.type('#adminlogin', 'Crash')

View file

@ -5,17 +5,16 @@ def create_conversation(playwright: Playwright) -> str:
browser = playwright.chromium.launch(headless=True)
context = browser.new_context()
page = context.new_page()
page.set_default_timeout(120_000)
page.goto("http://nc/")
page.get_by_label("Account name or email").click()
page.get_by_label("Account name or email").fill("Crash")
page.get_by_label("Account name or email").press("Tab")
page.get_by_label("Password", exact=True).fill("Override")
page.get_by_role("button", name="Log in").click()
try:
page.get_by_role("button", name="Close modal").click(timeout=3000)
except Exception:
pass
# Wait for the modal to load. As it seems you can't close it while it is showing the opening animation.
page.get_by_role("button", name="Close modal").click(timeout=15_000)
page.get_by_role("link", name="Talk", exact=True).click()
page.get_by_role("button", name="Create a new group conversation").click()
page.get_by_placeholder("Conversation name").fill("Random talk")
@ -36,9 +35,7 @@ def talk(playwright: Playwright, url: str) -> None:
context_one = browser_one.new_context()
context_two = browser_two.new_context()
user_one = context_one.new_page()
user_one.set_default_timeout(120_000)
user_two = context_two.new_page()
user_two.set_default_timeout(120_000)
user_one.goto(url)
user_two.goto(url)