Skip to content

BF (codename "happy travis"): trying to address lints etc to make Travis green again #702

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 14 commits into from
Dec 11, 2017
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
BF(WIN): use where instead of which while looking for git
  • Loading branch information
yarikoptic committed Nov 28, 2017
commit b4459ca7fd21d549a2342a902cfdeba10c76a022
5 changes: 4 additions & 1 deletion git/test/test_git.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@
except ImportError:
import mock

from git.compat import is_win


class TestGit(TestBase):

Expand Down Expand Up @@ -177,7 +179,8 @@ def test_refresh(self):
self.assertRaises(GitCommandNotFound, refresh, "yada")

# test a good path refresh
path = os.popen("which git").read().strip()
which_cmd = "where" if is_win else "which"
path = os.popen("{0} git".format(which_cmd)).read().strip()
refresh(path)

def test_options_are_passed_to_git(self):
Expand Down