tests: remove TestDir (#8502)

remove TestDir
This commit is contained in:
skshetry
2022-11-01 11:28:09 +05:45
committed by GitHub
parent 4b720e5820
commit 5e883bc00c
2 changed files with 3 additions and 9 deletions
+1 -7
View File
@@ -94,7 +94,7 @@ class TestDirFixture:
self._popd()
try:
remove(self._root_dir)
except OSError as exc:
except OSError as exc: # pragma: no cover
# pylint: disable=no-member
# We ignore this under Windows with a warning because it happened
# to be really hard to trace all not properly closed files.
@@ -149,12 +149,6 @@ class TestDvcGitFixture(TestGitFixture):
# NOTE: Inheritance order in the classes below is important.
class TestDir(TestDirFixture, TestCase):
def __init__(self, methodName):
TestDirFixture.__init__(self)
TestCase.__init__(self, methodName)
class TestDvc(TestDvcFixture, TestCase):
def __init__(self, methodName):
TestDvcFixture.__init__(self)
+2 -2
View File
@@ -12,7 +12,7 @@ from dvc.fs import LocalFileSystem
from dvc.repo import Repo as DvcRepo
from dvc.utils.fs import remove
from dvc_data.hashfile.db.local import LocalHashFileDB
from tests.basic_env import TestDir, TestDvcGit
from tests.basic_env import TestDvcGit
class TestGC(TestDvcGit):
@@ -122,7 +122,7 @@ class TestGCMultipleDvcRepos(TestDvcGit):
def setUp(self):
super().setUp()
self.additional_path = TestDir.mkdtemp()
self.additional_path = self.mkdtemp()
self.additional_git = Repo.init(self.additional_path)
self.additional_dvc = DvcRepo.init(self.additional_path)