aboutsummaryrefslogtreecommitdiff
path: root/tests/tasks
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--tests/tasks/test_scanner.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/tasks/test_scanner.py b/tests/tasks/test_scanner.py
index 7aefff4..5a1e5f2 100644
--- a/tests/tasks/test_scanner.py
+++ b/tests/tasks/test_scanner.py
@@ -2297,6 +2297,16 @@ def test_scan_sources_returns_when_source_directory_is_not_configured(
assert db.session.scalar(sa.select(Source)) is None
+def test_scan_sources_rejects_missing_source_directory(
+ app: Flask, scanner_module: ModuleType, tmp_path: Path
+) -> None:
+ path = tmp_path / "missing"
+ configure_scanner(app, path)
+
+ with pytest.raises(RuntimeError, match="Source directory is not a directory"):
+ run_scan(app, scanner_module)
+
+
def test_scan_sources_rejects_source_directory_that_is_not_directory(
app: Flask, scanner_module: ModuleType, tmp_path: Path
) -> None: