mirror of
https://github.com/willmiao/ComfyUI-Lora-Manager.git
synced 2026-03-23 22:22:11 -03:00
refactor(model_scanner): normalize path comparisons for model roots
fix(example_images_download_manager): re-raise specific exception on download error refactor(usage_stats): define constants locally to avoid conditional imports test(example_images_download_manager): update exception handling in download tests test(example_images_file_manager): differentiate between os.startfile and subprocess.Popen in tests test(example_images_paths): ensure valid example images root with single-library mode test(usage_stats): use string literals for metadata payload to avoid conditional imports
This commit is contained in:
@@ -30,10 +30,12 @@ def restore_settings() -> None:
|
||||
async def test_start_download_requires_configured_path(monkeypatch: pytest.MonkeyPatch) -> None:
|
||||
manager = download_module.DownloadManager(ws_manager=RecordingWebSocketManager())
|
||||
|
||||
with pytest.raises(download_module.ExampleImagesDownloadError) as exc_info:
|
||||
# Ensure example_images_path is not configured
|
||||
settings.settings.pop('example_images_path', None)
|
||||
|
||||
with pytest.raises(download_module.DownloadConfigurationError) as exc_info:
|
||||
await manager.start_download({})
|
||||
|
||||
assert isinstance(exc_info.value.__cause__, download_module.DownloadConfigurationError)
|
||||
assert "not configured" in str(exc_info.value)
|
||||
|
||||
result = await manager.start_download({"auto_mode": True})
|
||||
|
||||
Reference in New Issue
Block a user