Skip to content

Commit

Permalink
Also clear cache mid-tests for Windows after CI runner update
Browse files Browse the repository at this point in the history
  • Loading branch information
tomaarsen committed Aug 20, 2024
1 parent add421f commit cdc51c0
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
from __future__ import annotations

import os
import platform
import tempfile

import pytest
Expand Down Expand Up @@ -57,10 +56,8 @@ def cache_dir():
"""
In the CI environment, we use a temporary directory as `cache_dir`
to avoid keeping the downloaded models on disk after the test.
This is only required for Ubuntu, as we otherwise have disk space issues there.
"""
if os.environ.get("CI", None) and platform.system() == "Linux":
if os.environ.get("CI", None):
with tempfile.TemporaryDirectory() as tmp_dir:
yield tmp_dir
else:
Expand Down

0 comments on commit cdc51c0

Please sign in to comment.