diff --git a/test/test_datasets_download.py b/test/test_datasets_download.py index cf0211dbb1e..71aeb9ea774 100644 --- a/test/test_datasets_download.py +++ b/test/test_datasets_download.py @@ -1,12 +1,12 @@ import contextlib import itertools +import shutil import tempfile import time import traceback import unittest.mock import warnings from datetime import datetime -from distutils import dir_util from os import path from urllib.error import HTTPError, URLError from urllib.parse import urlparse @@ -180,7 +180,7 @@ def collect_urls(dataset_cls, *args, **kwargs): @pytest.fixture(scope="module", autouse=True) def root(): yield ROOT - dir_util.remove_tree(ROOT) + shutil.rmtree(ROOT) def places365():