From c5eb9e1686fec91b1f653e50a20935e6447ce3cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Przemys=C5=82aw=20Ro=C5=BCnawski?= Date: Wed, 27 Dec 2023 18:30:04 +0100 Subject: [PATCH] Allow for ignoring file tests locally --- README.md | 5 +++++ pyproject.toml | 5 +++++ tests/test_room_api.py | 1 + 3 files changed, 11 insertions(+) diff --git a/README.md b/README.md index 3f90fa4..d97fc80 100644 --- a/README.md +++ b/README.md @@ -98,6 +98,11 @@ You can test the SDK by running poetry run ci_test ``` +In local development you can use +``` +poetry run pytest -m "not file_component_sources" +``` + ## Format & Lint You can format code by running ```console diff --git a/pyproject.toml b/pyproject.toml index 2a90b93..f1bf557 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,3 +55,8 @@ ignore = [] [tool.ruff.extend-per-file-ignores] "jellyfish/_openapi_client/**" = ["E501"] + +[tool.pytest.ini_options] +markers = [ + "file_component_sources: Tests requiring files uploaded for File Component" +] diff --git a/tests/test_room_api.py b/tests/test_room_api.py index e62db17..ac4a479 100644 --- a/tests/test_room_api.py +++ b/tests/test_room_api.py @@ -234,6 +234,7 @@ def test_with_options_rtsp(self, room_api: RoomApi): assert response == component_rtsp assert component == component_rtsp + @pytest.mark.file_component_sources def test_with_options_file(self, room_api: RoomApi): _, room = room_api.create_room()