diff --git a/tests/unit/test_batch_download.py b/tests/unit/test_batch_download.py index fd6813f31..b88f9bc59 100755 --- a/tests/unit/test_batch_download.py +++ b/tests/unit/test_batch_download.py @@ -260,6 +260,7 @@ def test_batch_download_session_closed(): to avoid stale PromiseProxy cache from prior tests in the suite. """ import worker_app.db as _db_mod + from apps.worker.worker_app.tasks.batch_download import batch_download_videos videos = [_FakeVideo("v1", "v.mp4")] @@ -291,6 +292,7 @@ def test_batch_download_session_closed(): def test_batch_download_closes_session_on_error(): """Session is closed even when get_by_ids raises.""" import worker_app.db as _db_mod + from apps.worker.worker_app.tasks.batch_download import batch_download_videos class _ExplodingRepo: