X-Git-Url: https://plomlompom.com/repos/berlin_corona.txt?a=blobdiff_plain;f=tests%2Futils.py;h=c1a22b64fb56c9c4fd566245ce047c1d7fff428d;hb=e60bbd142b5026748ee2181ca6758afef6202fb4;hp=bb37270ca68afde8e00df09a19892011fd371a29;hpb=80491fac3c476788d90010812c9ba0b95701e09b;p=plomtask diff --git a/tests/utils.py b/tests/utils.py index bb37270..c1a22b6 100644 --- a/tests/utils.py +++ b/tests/utils.py @@ -45,8 +45,7 @@ class TestCaseWithDB(TestCase): ProcessStep.empty_cache() Todo.empty_cache() timestamp = datetime.now().timestamp() - self.db_file = DatabaseFile(f'test_db:{timestamp}') - self.db_file.remake() + self.db_file = DatabaseFile.create_at(f'test_db:{timestamp}') self.db_conn = DatabaseConnection(self.db_file) def tearDown(self) -> None: @@ -68,7 +67,7 @@ class TestCaseWithDB(TestCase): row)] self.assertEqual(sorted(content), sorted(db_found)) - def check_saving_and_caching(self, **kwargs: Any) -> Any: + def check_saving_and_caching(self, **kwargs: Any) -> None: """Test instance.save in its core without relations.""" obj = self.checked_class(**kwargs) # pylint: disable=not-callable # check object init itself doesn't store anything yet