Skip to content

Commit

Permalink
🐛E2e: Playwright disable web security (#5753)
Browse files Browse the repository at this point in the history
  • Loading branch information
sanderegg authored Apr 29, 2024
1 parent aab64d4 commit 2ac3032
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions tests/e2e-playwright/tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,10 +158,17 @@ def user_agent(request: pytest.FixtureRequest) -> str:
return str(request.config.getoption("--user-agent"))


@pytest.fixture(scope="session")
def browser_type_launch_args(browser_type_launch_args: dict, user_agent: str) -> dict:
# NOTE: Until the dynamic sidecar is setup with https://doc.traefik.io/traefik/middlewares/http/headers/#accesscontrolallowheaders
# this must remain. until https://github.com/ITISFoundation/osparc-simcore/issues/5754 is completed
return {**browser_type_launch_args, "args": ["--disable-web-security"]}


@pytest.fixture(scope="session")
def browser_context_args(
browser_context_args: dict[str, dict[str, str]], user_agent: str
) -> dict[str, dict[str, str]]:
browser_context_args: dict[str, dict[str, str] | str], user_agent: str
) -> dict[str, dict[str, str] | str]:
# Override browser context options, see https://playwright.dev/python/docs/test-runners#fixtures
return {
**browser_context_args,
Expand Down

0 comments on commit 2ac3032

Please sign in to comment.