diff options
author | Sebastian Thiel <byronimo@gmail.com> | 2015-02-09 19:22:18 +0100 |
---|---|---|
committer | Sebastian Thiel <byronimo@gmail.com> | 2015-02-09 19:22:18 +0100 |
commit | fe426d404b727d0567f21871f61cc6dc881e8bf0 (patch) | |
tree | c5f4042a65ab7ba598c8110bb12340afb8cdc4c3 /git/test/lib/helper.py | |
parent | 756b7ad43d0ad18858075f90ce5eaec2896d439c (diff) | |
download | gitpython-fe426d404b727d0567f21871f61cc6dc881e8bf0.tar.gz |
Minor Flake8 fixes.
Latest version of it is required to show the issues travis shows as well
Diffstat (limited to 'git/test/lib/helper.py')
-rw-r--r-- | git/test/lib/helper.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/git/test/lib/helper.py b/git/test/lib/helper.py index 5efb7d9d..31bee78f 100644 --- a/git/test/lib/helper.py +++ b/git/test/lib/helper.py @@ -15,7 +15,9 @@ import io from git import Repo, Remote, GitCommandError, Git from git.compat import string_types -GIT_REPO = os.environ.get("GIT_PYTHON_TEST_GIT_REPO_BASE", os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(__file__))))) +osp = os.path.dirname + +GIT_REPO = os.environ.get("GIT_PYTHON_TEST_GIT_REPO_BASE", osp(osp(osp(osp(__file__))))) __all__ = ( 'fixture_path', 'fixture', 'absolute_project_path', 'StringProcessAdapter', @@ -26,7 +28,7 @@ __all__ = ( def fixture_path(name): - test_dir = os.path.dirname(os.path.dirname(__file__)) + test_dir = osp(osp(__file__)) return os.path.join(test_dir, "fixtures", name) @@ -35,7 +37,7 @@ def fixture(name): def absolute_project_path(): - return os.path.abspath(os.path.join(os.path.dirname(__file__), "..", "..")) + return os.path.abspath(os.path.join(osp(__file__), "..", "..")) #} END routines @@ -195,7 +197,7 @@ def with_rw_and_rw_remote_repo(working_tree_ref): d_remote.config_writer.set('url', remote_repo_url) - temp_dir = os.path.dirname(_mktemp()) + temp_dir = osp(_mktemp()) # On windows, this will fail ... we deal with failures anyway and default to telling the user to do it try: gd = Git().daemon(temp_dir, enable='receive-pack', as_process=True) |