diff options
author | Sebastian Thiel <sebastian.thiel@icloud.com> | 2022-05-18 07:43:53 +0800 |
---|---|---|
committer | Sebastian Thiel <sebastian.thiel@icloud.com> | 2022-05-18 07:43:53 +0800 |
commit | 21ec529987d10e0010badd37f8da3274167d436f (patch) | |
tree | a3394cfe902ce7edd07c89420c21c13274a2d295 /test/performance/lib.py | |
parent | b30720ee4d9762a03eae4fa7cfa4b0190d81784d (diff) | |
download | gitpython-21ec529987d10e0010badd37f8da3274167d436f.tar.gz |
Run everything through 'black'
That way people who use it won't be deterred, while it unifies style
everywhere.
Diffstat (limited to 'test/performance/lib.py')
-rw-r--r-- | test/performance/lib.py | 43 |
1 files changed, 23 insertions, 20 deletions
diff --git a/test/performance/lib.py b/test/performance/lib.py index 86f87757..101e2cd4 100644 --- a/test/performance/lib.py +++ b/test/performance/lib.py @@ -3,27 +3,21 @@ import logging import os import tempfile -from git import ( - Repo -) -from git.db import ( - GitCmdObjectDB, - GitDB -) -from test.lib import ( - TestBase -) +from git import Repo +from git.db import GitCmdObjectDB, GitDB +from test.lib import TestBase from git.util import rmtree import os.path as osp -#{ Invariants +# { Invariants k_env_git_repo = "GIT_PYTHON_TEST_GIT_REPO_BASE" -#} END invariants +# } END invariants -#{ Base Classes +# { Base Classes + class TestBigRepoR(TestBase): @@ -39,8 +33,8 @@ class TestBigRepoR(TestBase): * As gitrepo, but uses pure python implementation """ - #{ Invariants - #} END invariants + # { Invariants + # } END invariants def setUp(self): try: @@ -51,11 +45,17 @@ class TestBigRepoR(TestBase): repo_path = os.environ.get(k_env_git_repo) if repo_path is None: logging.info( - ("You can set the %s environment variable to a .git repository of" % k_env_git_repo) + - "your choice - defaulting to the gitpython repository") + ( + "You can set the %s environment variable to a .git repository of" + % k_env_git_repo + ) + + "your choice - defaulting to the gitpython repository" + ) repo_path = osp.dirname(__file__) # end set some repo path - self.gitrorepo = Repo(repo_path, odbt=GitCmdObjectDB, search_parent_directories=True) + self.gitrorepo = Repo( + repo_path, odbt=GitCmdObjectDB, search_parent_directories=True + ) self.puregitrorepo = Repo(repo_path, odbt=GitDB, search_parent_directories=True) def tearDown(self): @@ -79,7 +79,9 @@ class TestBigRepoRW(TestBigRepoR): pass dirname = tempfile.mktemp() os.mkdir(dirname) - self.gitrwrepo = self.gitrorepo.clone(dirname, shared=True, bare=True, odbt=GitCmdObjectDB) + self.gitrwrepo = self.gitrorepo.clone( + dirname, shared=True, bare=True, odbt=GitCmdObjectDB + ) self.puregitrwrepo = Repo(dirname, odbt=GitDB) def tearDown(self): @@ -91,4 +93,5 @@ class TestBigRepoRW(TestBigRepoR): self.puregitrwrepo.git.clear_cache() self.puregitrwrepo = None -#} END base classes + +# } END base classes |