Skip to content

Commit 2ca3d56

Browse files
committed
Stabilize UI import storage test in CI
1 parent ad4a7eb commit 2ca3d56

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

tests/test_ui.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,11 +117,12 @@ def test_import_requires_file_or_path(self, client):
117117
resp = client.post("/api/models/import", json={})
118118
assert resp.status_code == 400
119119

120-
def test_import_returns_507_when_storage_is_full(self, client):
120+
def test_import_returns_507_when_storage_is_full(self, client, tmp_path):
121121
from io import BytesIO
122122

123123
data = {"file": (BytesIO(b"fake"), "model.gguf")}
124124
with patch("ui.app._ui_audit.append") as mock_append, \
125+
patch("ui.app.QUARANTINE_DIR", tmp_path / "quarantine"), \
125126
patch(
126127
"werkzeug.datastructures.file_storage.FileStorage.save",
127128
side_effect=OSError(errno.ENOSPC, "No space left on device"),

0 commit comments

Comments
 (0)