Skip to content

Commit

Permalink
chore(ci): Skip all chat tests on webkit (#1575)
Browse files Browse the repository at this point in the history
  • Loading branch information
schloerke authored Jul 26, 2024
1 parent 4d2056e commit 8b65ca3
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
from playwright.sync_api import Page, expect
from utils.deploy_utils import skip_on_webkit

from shiny.playwright import controller
from shiny.run import ShinyAppProc


@skip_on_webkit
def test_validate_chat_append_user_message(page: Page, local_app: ShinyAppProc) -> None:
page.goto(local_app.url)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
from playwright.sync_api import Page, expect
from utils.deploy_utils import skip_on_webkit

from shiny.playwright import controller
from shiny.run import ShinyAppProc


@skip_on_webkit
def test_validate_chat_basic(page: Page, local_app: ShinyAppProc) -> None:
page.goto(local_app.url)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
from playwright.sync_api import Page, expect
from utils.deploy_utils import skip_on_webkit

from shiny.playwright import controller
from shiny.run import ShinyAppProc


@skip_on_webkit
def test_validate_chat_basic_error(page: Page, local_app: ShinyAppProc) -> None:
page.goto(local_app.url)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
import re

from playwright.sync_api import Page, expect
from utils.deploy_utils import skip_on_webkit

from shiny.playwright import controller
from shiny.run import ShinyAppProc


@skip_on_webkit
def test_validate_chat(page: Page, local_app: ShinyAppProc) -> None:
page.goto(local_app.url)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
from playwright.sync_api import Page, expect
from utils.deploy_utils import skip_on_webkit

from shiny.playwright import controller
from shiny.run import ShinyAppProc


@skip_on_webkit
def test_validate_chat_transform(page: Page, local_app: ShinyAppProc) -> None:
page.goto(local_app.url)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
from playwright.sync_api import Page, expect
from utils.deploy_utils import skip_on_webkit

from shiny import ui
from shiny.playwright import controller
from shiny.run import ShinyAppProc


@skip_on_webkit
def test_validate_chat_transform_assistant(page: Page, local_app: ShinyAppProc) -> None:
page.goto(local_app.url)

Expand Down
6 changes: 6 additions & 0 deletions tests/playwright/utils/deploy_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ def skip_if_not_chrome(fn: CallableT) -> CallableT:
return fn


def skip_on_webkit(fn: CallableT) -> CallableT:
fn = pytest.mark.skip_browser("webkit")(fn)

return fn


def run_command(cmd: str) -> str:
output = subprocess.run(
cmd,
Expand Down

0 comments on commit 8b65ca3

Please sign in to comment.