test: close pools on tests cleanup

This avoids weird errors as pools are collected by gc in broken env.
This commit is contained in:
Alexander Schepanovski
2019-07-21 13:40:29 +07:00
parent 31f1ded315
commit 6afc2a38ba
+8
View File
@@ -169,3 +169,11 @@ def erepo(repo_dir):
yield repo
finally:
repo.tearDown()
@pytest.fixture(scope="session", autouse=True)
def _close_pools():
from dvc.remote.pool import close_pools
yield
close_pools()