diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 6efe0f25..79e59a8e 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -70,18 +70,9 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-22.04, windows-2022] - python-version: ["3.8", "3.11"] - pip-extras: ["lab", "classic"] - exclude: - # windows should work for all test variations, but a limited selection - # is run to avoid doubling the amount of test runs - - os: windows-2022 - python-version: "3.11" - pip-extras: classic - - os: windows-2022 - python-version: "3.8" - pip-extras: lab + os: [ubuntu-22.04] + python-version: ["3.11"] + pip-extras: ["lab"] steps: - uses: actions/checkout@v4 diff --git a/tests/acceptance/Lab.robot b/tests/acceptance/Lab.robot index b0341d58..eae73ee9 100644 --- a/tests/acceptance/Lab.robot +++ b/tests/acceptance/Lab.robot @@ -9,35 +9,12 @@ Suite Setup Start Lab Tests Test Tags app:lab -*** Variables *** -${CSS_LAUNCHER_CARD} css:.jp-LauncherCard-label - *** Test Cases *** Lab Loads Capture Page Screenshot 00-smoke.png -Launch Browser Tab - Click Launcher foo - Wait Until Keyword Succeeds 3x 0.5s Switch Window title:Hello World - Location Should Contain foo - Wait Until Page Contains Hello World timeout=10s - Close Window - [Teardown] Switch Window title:JupyterLab - -Launch Lab Tab - Click Launcher bar - Wait Until Page Contains Element css:iframe - Select Frame css:iframe - Wait Until Page Contains Hello World timeout=10s - *** Keywords *** Start Lab Tests Open JupyterLab Tag With JupyterLab Metadata Set Screenshot Directory ${OUTPUT DIR}${/}lab - -Click Launcher - [Arguments] ${title} - ${item} = Set Variable ${CSS_LAUNCHER_CARD}\[title^\="${title}"] - Wait Until Element Is Visible ${item} timeout=10s - Click Element ${item} diff --git a/tests/acceptance/test_acceptance.py b/tests/acceptance/test_acceptance.py index 99c5547d..aa0f1d79 100644 --- a/tests/acceptance/test_acceptance.py +++ b/tests/acceptance/test_acceptance.py @@ -3,57 +3,25 @@ import subprocess from pathlib import Path -import pytest - HERE = Path(__file__).parent OUTPUT = HERE.parent.parent / "build/robot" -JUPYTER_SERVER_INFO = None - - -try: - import notebook - - NOTEBOOK_VERSION = int(notebook.__version__.split(".")[0]) -except ImportError: - NOTEBOOK_VERSION = None - -try: - import jupyter_server - - JUPYTER_SERVER_INFO = jupyter_server.version_info -except ImportError: - pass def test_robot(): """run acceptance tests with robotframework""" - pytest.importorskip("JupyterLibrary") - - env = dict(**os.environ) robot_args = [ "robot", "--consolecolors=on", + "--include=app:lab", "--exitonfailure", f"--outputdir={OUTPUT}", ] - if NOTEBOOK_VERSION and NOTEBOOK_VERSION >= 7: - robot_args += ["--exclude", "app:classic"] - else: - robot_args += ["--exclude", "app:notebook"] - - # JUPYTER_LIBRARY_* env vars documentation: - # https://robotframework-jupyterlibrary.readthedocs.io/en/stable/LIMITS.html#notebookapp-vs-serverapp - if JUPYTER_SERVER_INFO is None: - env.update( - JUPYTER_LIBRARY_APP_COMMAND="jupyter-notebook", - JUPYTER_LIBRARY_APP="NotebookApp", - ) - else: - env.update( - JUPYTER_LIBRARY_APP_COMMAND="jupyter-server", - JUPYTER_LIBRARY_APP="ServerApp", - ) + env = dict(**os.environ) + env.update( + JUPYTER_LIBRARY_APP_COMMAND="jupyter-server", + JUPYTER_LIBRARY_APP="ServerApp", + ) if OUTPUT.exists(): shutil.rmtree(OUTPUT)