Skip to content

Commit 849bbf8

Browse files
committed
fixing tests
1 parent 140e497 commit 849bbf8

File tree

5 files changed

+7
-9
lines changed

5 files changed

+7
-9
lines changed

services/web/server/tests/unit/with_dbs/04/folders/test_folders.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -371,10 +371,6 @@ async def test_project_listing_inside_of_private_folder(
371371

372372
@pytest.fixture
373373
def mock_storage_delete_data_folders(mocker: MockerFixture) -> mock.Mock:
374-
mocker.patch(
375-
"simcore_service_webserver.dynamic_scheduler.api.list_dynamic_services",
376-
autospec=True,
377-
)
378374
mocker.patch(
379375
"simcore_service_webserver.projects._projects_service.remove_project_dynamic_services",
380376
autospec=True,
@@ -391,8 +387,8 @@ def mock_storage_delete_data_folders(mocker: MockerFixture) -> mock.Mock:
391387

392388
@pytest.mark.parametrize("user_role,expected", [(UserRole.USER, status.HTTP_200_OK)])
393389
async def test_folders_deletion(
394-
client: TestClient,
395390
mocked_dynamic_services_interface: dict[str, mock.MagicMock],
391+
client: TestClient,
396392
logged_user: UserInfoDict,
397393
user_project: ProjectDict,
398394
expected: HTTPStatus,

services/web/server/tests/unit/with_dbs/04/notifications/test_notifications__db_comp_tasks_listening_task.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,7 @@ async def _check_for_stability(
259259

260260
@pytest.mark.parametrize("user_role", [UserRole.USER])
261261
async def test_db_listener_upgrades_projects_row_correctly(
262+
mocked_dynamic_services_interface: dict[str, mock.MagicMock],
262263
with_started_listening_task: None,
263264
mock_dynamic_service_rpc: mock.AsyncMock,
264265
sqlalchemy_async_engine: AsyncEngine,

services/web/server/tests/unit/with_dbs/04/workspaces/test_workspaces__delete_workspace_with_content.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,6 @@
2323

2424
@pytest.fixture
2525
def mock_storage_delete_data_folders(mocker: MockerFixture) -> mock.Mock:
26-
mocker.patch(
27-
"simcore_service_webserver.dynamic_scheduler.api.list_dynamic_services",
28-
autospec=True,
29-
)
3026
mocker.patch(
3127
"simcore_service_webserver.projects._projects_service.remove_project_dynamic_services",
3228
autospec=True,

services/web/server/tests/unit/with_dbs/04/workspaces/test_workspaces__moving_folders_between_workspaces.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,7 @@ async def _move_folder_to_workspace_and_assert(
185185

186186

187187
async def test_moving_between_private_and_shared_workspaces(
188+
mocked_dynamic_services_interface: dict[str, mock.MagicMock],
188189
client: TestClient,
189190
logged_user: UserInfoDict,
190191
fake_project: ProjectDict,

services/web/server/tests/unit/with_dbs/04/workspaces/test_workspaces__moving_projects_between_workspaces.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
from copy import deepcopy
99
from http import HTTPStatus
10+
from unittest import mock
1011

1112
import pytest
1213
import sqlalchemy as sa
@@ -43,6 +44,7 @@ async def test_moving_between_workspaces_user_role_permissions(
4344

4445
@pytest.mark.parametrize("user_role,expected", [(UserRole.USER, status.HTTP_200_OK)])
4546
async def test_moving_between_private_and_shared_workspaces(
47+
mocked_dynamic_services_interface: dict[str, mock.MagicMock],
4648
client: TestClient,
4749
logged_user: UserInfoDict,
4850
user_project: ProjectDict,
@@ -109,6 +111,7 @@ async def test_moving_between_private_and_shared_workspaces(
109111

110112
@pytest.mark.parametrize("user_role,expected", [(UserRole.USER, status.HTTP_200_OK)])
111113
async def test_moving_between_shared_and_shared_workspaces(
114+
mocked_dynamic_services_interface: dict[str, mock.MagicMock],
112115
client: TestClient,
113116
logged_user: UserInfoDict,
114117
user_project: ProjectDict,
@@ -174,6 +177,7 @@ async def test_moving_between_shared_and_shared_workspaces(
174177

175178
@pytest.mark.parametrize("user_role,expected", [(UserRole.USER, status.HTTP_200_OK)])
176179
async def test_moving_between_workspaces_check_removed_from_folder(
180+
mocked_dynamic_services_interface: dict[str, mock.MagicMock],
177181
client: TestClient,
178182
logged_user: UserInfoDict,
179183
user_project: ProjectDict,

0 commit comments

Comments
 (0)