aboutsummaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorMichael J Gruber <git@drmicha.warpmail.net>2016-03-04 11:53:50 +0100
committerJunio C Hamano <gitster@pobox.com>2016-03-04 10:22:55 -0800
commit816c19308b39d0f9f6d15e8320aa1d2ab148e3d2 (patch)
tree1a0cc73976b8c718ffdcfb58e9266b145a515de4 /t
parentd5621020c1e0edfa998cb5c5e80cdf47f36ffb1a (diff)
downloadgit-816c19308b39d0f9f6d15e8320aa1d2ab148e3d2.tar.gz
git-816c19308b39d0f9f6d15e8320aa1d2ab148e3d2.tar.xz
t5510: do not leave changed cwd
t5510 carefully keeps the cwd at the test root by using either subshells or explicit cd'ing back to the root. Use a subshell for the last subtest, too. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-xt/t5510-fetch.sh10
1 files changed, 6 insertions, 4 deletions
diff --git a/t/t5510-fetch.sh b/t/t5510-fetch.sh
index e3ee4bd70..5b52c877c 100755
--- a/t/t5510-fetch.sh
+++ b/t/t5510-fetch.sh
@@ -715,10 +715,12 @@ test_expect_success 'fetching with auto-gc does not lock up' '
EOF
git clone "file://$D" auto-gc &&
test_commit test2 &&
- cd auto-gc &&
- git config gc.autoPackLimit 1 &&
- GIT_ASK_YESNO="$D/askyesno" git fetch >fetch.out 2>&1 &&
- ! grep "Should I try again" fetch.out
+ (
+ cd auto-gc &&
+ git config gc.autoPackLimit 1 &&
+ GIT_ASK_YESNO="$D/askyesno" git fetch >fetch.out 2>&1 &&
+ ! grep "Should I try again" fetch.out
+ )
'
test_done