From 1cbf21be959207b9a7fcab759820e97d9736e0dd Mon Sep 17 00:00:00 2001 From: hay-kot Date: Wed, 5 May 2021 12:55:37 -0800 Subject: [PATCH] fix theme tests --- tests/integration_tests/test_settings_routes.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/integration_tests/test_settings_routes.py b/tests/integration_tests/test_settings_routes.py index 2076d37db..c6e4bbd62 100644 --- a/tests/integration_tests/test_settings_routes.py +++ b/tests/integration_tests/test_settings_routes.py @@ -20,7 +20,7 @@ def default_theme(): @pytest.fixture(scope="session") def new_theme(): return { - "id": 2, + "id": 3, "name": "myTestTheme", "colors": { "primary": "#E58325", @@ -73,7 +73,9 @@ def test_create_theme(api_client: TestClient, api_routes: AppRoutes, new_theme, def test_read_all_themes(api_client: TestClient, api_routes: AppRoutes, default_theme, new_theme): response = api_client.get(api_routes.themes) assert response.status_code == 200 - assert json.loads(response.content) == [default_theme, new_theme] + response_dict = json.loads(response.content) + assert default_theme in response_dict + assert new_theme in response_dict def test_read_theme(api_client: TestClient, api_routes: AppRoutes, default_theme, new_theme):