From 51bf7cbe8216d9a1da723c59b6feece0b1a34589 Mon Sep 17 00:00:00 2001 From: Kostis Anagnostopoulos Date: Sun, 25 Sep 2016 18:08:16 +0200 Subject: win: GC.collect on all TC.tearDown to fix appveyor hang runs + Fixed the hangs at `test_git:TestGit.test_handle_process_output()`. [travisci skip] --- git/test/performance/test_commit.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'git/test/performance') diff --git a/git/test/performance/test_commit.py b/git/test/performance/test_commit.py index b59c747e..c60dc2fc 100644 --- a/git/test/performance/test_commit.py +++ b/git/test/performance/test_commit.py @@ -17,6 +17,10 @@ from git.test.test_commit import assert_commit_serialization class TestPerformance(TestBigRepoRW): + def tearDown(self): + import gc + gc.collect() + # ref with about 100 commits in its history ref_100 = '0.1.6' -- cgit v1.2.1 From 137ee6ef22c4e6480f95972ef220d1832cdc709a Mon Sep 17 00:00:00 2001 From: Kostis Anagnostopoulos Date: Tue, 27 Sep 2016 22:07:19 +0200 Subject: Win, #519: FIX with_rw_directory() to remove read-only dirs + Stop using gitdb's respective helper. + Fix files chmod(555) which CANNOT DELETE on Windows (but do on Linux). --- git/test/performance/lib.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'git/test/performance') diff --git a/git/test/performance/lib.py b/git/test/performance/lib.py index bb3f7a99..eebbfd76 100644 --- a/git/test/performance/lib.py +++ b/git/test/performance/lib.py @@ -4,7 +4,6 @@ from git.test.lib import ( TestBase ) from gitdb.test.lib import skip_on_travis_ci -import shutil import tempfile import logging @@ -16,6 +15,7 @@ from git.db import ( from git import ( Repo ) +from git.util import rmtree #{ Invvariants k_env_git_repo = "GIT_PYTHON_TEST_GIT_REPO_BASE" @@ -86,7 +86,7 @@ class TestBigRepoRW(TestBigRepoR): def tearDown(self): super(TestBigRepoRW, self).tearDown() if self.gitrwrepo is not None: - shutil.rmtree(self.gitrwrepo.working_dir) + rmtree(self.gitrwrepo.working_dir) self.gitrwrepo.git.clear_cache() self.gitrwrepo = None self.puregitrwrepo.git.clear_cache() -- cgit v1.2.1 From 395955609dfd711cc4558e2b618450f3514b28c1 Mon Sep 17 00:00:00 2001 From: Kostis Anagnostopoulos Date: Thu, 29 Sep 2016 01:07:41 +0200 Subject: FIX hook TC on PY3+Win & indeterministic lock timing. + Cannot `index.path` into ENV, it is bytes! + The hook TC never runs on linux! + Unblock removal of odbfile in perf-large streams TC. + Attempt to unblock removal of submodule file by intensive cleaning. more unblock files --- git/test/performance/test_streams.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'git/test/performance') diff --git a/git/test/performance/test_streams.py b/git/test/performance/test_streams.py index 4b1738cd..8194547c 100644 --- a/git/test/performance/test_streams.py +++ b/git/test/performance/test_streams.py @@ -87,6 +87,9 @@ class TestObjDBPerformance(TestBigRepoR): % (size_kib, desc, cs_kib, elapsed_readchunks, size_kib / elapsed_readchunks), file=sys.stderr) # del db file so git has something to do + ostream = None + import gc + gc.collect() os.remove(db_file) # VS. CGIT -- cgit v1.2.1