summaryrefslogtreecommitdiff
path: root/t/t1308-config-set.sh
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2016-07-14 10:38:57 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2016-07-14 10:38:57 -0700
commit75676c8c8b6cbeec7ccb68d97c17db230d9f2659 (patch)
treeb3e24fcafb337e80531d899ddb0087a9d80f68f4 /t/t1308-config-set.sh
parentFifth batch of topics for 2.10 (diff)
parentmingw: fix regression in t1308-config-set (diff)
downloadtgif-75676c8c8b6cbeec7ccb68d97c17db230d9f2659.tar.xz
Merge branch 'jk/upload-pack-hook'
A hot-fix to make a test working in mingw again. * jk/upload-pack-hook: mingw: fix regression in t1308-config-set
Diffstat (limited to 't/t1308-config-set.sh')
-rwxr-xr-xt/t1308-config-set.sh10
1 files changed, 9 insertions, 1 deletions
diff --git a/t/t1308-config-set.sh b/t/t1308-config-set.sh
index a06e71ceed..7655c94c28 100755
--- a/t/t1308-config-set.sh
+++ b/t/t1308-config-set.sh
@@ -233,11 +233,19 @@ cmdline_config="'foo.bar=from-cmdline'"
test_expect_success 'iteration shows correct origins' '
echo "[foo]bar = from-repo" >.git/config &&
echo "[foo]bar = from-home" >.gitconfig &&
+ if test_have_prereq MINGW
+ then
+ # Use Windows path (i.e. *not* $HOME)
+ HOME_GITCONFIG=$(pwd)/.gitconfig
+ else
+ # Do not get fooled by symbolic links, i.e. $HOME != $(pwd)
+ HOME_GITCONFIG=$HOME/.gitconfig
+ fi &&
cat >expect <<-EOF &&
key=foo.bar
value=from-home
origin=file
- name=$HOME/.gitconfig
+ name=$HOME_GITCONFIG
scope=global
key=foo.bar