remove timeout and locale to replace with global timeout

This commit is contained in:
Daniel 2023-11-30 18:25:41 +01:00
parent 565903f304
commit 636c39d557
3 changed files with 2 additions and 16 deletions

View file

@ -6,15 +6,12 @@ from playwright.sync_api import BrowserContext, Page
from src.dirmanager import DirManager
TIMEOUT = 5000
@pytest.fixture
def wordpress_admin_context(context: BrowserContext, DIR: DirManager) -> BrowserContext:
state_file = DIR.STATES / "wordpress_admin_state.json"
storage_state = json.loads(state_file.read_bytes())
context.add_cookies(storage_state["cookies"])
context.set_default_timeout(TIMEOUT)
return context