Skip to content

Commit 3641078

Browse files
author
Andrei Neagu
committed
fixed import/initialize issues
1 parent db55a9a commit 3641078

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

services/dynamic-scheduler/tests/conftest.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
from pathlib import Path
77
from typing import Final
88

9+
import nicegui
910
import pytest
1011
import simcore_service_dynamic_scheduler
1112
import yaml
@@ -124,6 +125,9 @@ def disable_status_monitor_lifespan(mocker: MockerFixture) -> None:
124125
async def app(
125126
app_environment: EnvVarsDict, is_pdb_enabled: bool
126127
) -> AsyncIterator[FastAPI]:
128+
# forces rebuild of middleware stack on next test
129+
nicegui.app.user_middleware.clear()
130+
nicegui.app.middleware_stack = None
127131
test_app = create_app()
128132
async with LifespanManager(
129133
test_app,

0 commit comments

Comments
 (0)