summaryrefslogtreecommitdiff
path: root/t/t1300-config.sh
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2019-09-30 13:19:30 +0900
committerLibravatar Junio C Hamano <gitster@pobox.com>2019-09-30 13:19:30 +0900
commitd693345518e9d5145902ec001a364ccdec8e148b (patch)
treeb978cd237fbabe3459ce986ecb2378dafe1259c1 /t/t1300-config.sh
parentMerge branch 'jk/misc-uninitialized-fixes' (diff)
parentt: use common $SQ variable (diff)
downloadtgif-d693345518e9d5145902ec001a364ccdec8e148b.tar.xz
Merge branch 'dl/use-sq-from-test-lib'
Code cleanup. * dl/use-sq-from-test-lib: t: use common $SQ variable
Diffstat (limited to 't/t1300-config.sh')
-rwxr-xr-xt/t1300-config.sh9
1 files changed, 4 insertions, 5 deletions
diff --git a/t/t1300-config.sh b/t/t1300-config.sh
index 428177c390..983a0a1583 100755
--- a/t/t1300-config.sh
+++ b/t/t1300-config.sh
@@ -1294,26 +1294,25 @@ test_expect_success 'git -c is not confused by empty environment' '
GIT_CONFIG_PARAMETERS="" git -c x.one=1 config --list
'
-sq="'"
test_expect_success 'detect bogus GIT_CONFIG_PARAMETERS' '
cat >expect <<-\EOF &&
env.one one
env.two two
EOF
- GIT_CONFIG_PARAMETERS="${sq}env.one=one${sq} ${sq}env.two=two${sq}" \
+ GIT_CONFIG_PARAMETERS="${SQ}env.one=one${SQ} ${SQ}env.two=two${SQ}" \
git config --get-regexp "env.*" >actual &&
test_cmp expect actual &&
cat >expect <<-EOF &&
- env.one one${sq}
+ env.one one${SQ}
env.two two
EOF
- GIT_CONFIG_PARAMETERS="${sq}env.one=one${sq}\\$sq$sq$sq ${sq}env.two=two${sq}" \
+ GIT_CONFIG_PARAMETERS="${SQ}env.one=one${SQ}\\$SQ$SQ$SQ ${SQ}env.two=two${SQ}" \
git config --get-regexp "env.*" >actual &&
test_cmp expect actual &&
test_must_fail env \
- GIT_CONFIG_PARAMETERS="${sq}env.one=one${sq}\\$sq ${sq}env.two=two${sq}" \
+ GIT_CONFIG_PARAMETERS="${SQ}env.one=one${SQ}\\$SQ ${SQ}env.two=two${SQ}" \
git config --get-regexp "env.*"
'