From 16abd3d1e79c68c99d92e3055cf22ea2569b811b Mon Sep 17 00:00:00 2001 From: Wyatt Hoodes Date: Fri, 28 Jun 2019 13:42:20 -1000 Subject: [PATCH] test-backend: Remove long-term clean up code. With the refactored file structure approach, the clean up block at the end of `test-backend` is no longer necessary. --- tools/test-backend | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/tools/test-backend b/tools/test-backend index 902d5bfddb..d1558c6af7 100755 --- a/tools/test-backend +++ b/tools/test-backend @@ -16,7 +16,6 @@ import ujson import httplib2 import httpretty import requests -import shutil import django from django.conf import settings @@ -457,21 +456,6 @@ def main() -> None: # an important clue as to why tests fail. report_slow_tests() - # We now cleanup files leaked by certain tests that don't clean up - # after themselves. Ideally, this cleanup would happen in in the - # tearDown() methods for the relevant test classes, but this at least - # prevents a disk leak. - from scripts.lib.zulip_tools import get_or_create_dev_uuid_var_path - for path in glob.glob(os.path.join(get_or_create_dev_uuid_var_path('test-backend'), - "test-*-import-*")): - try: - if os.path.isdir(path): - shutil.rmtree(path) - else: - os.remove(path) - except FileNotFoundError: - pass - # Ideally, we'd check for any leaked test databases here; # but that needs some hackery with database names. #