From: Junio C Hamano Date: Thu, 25 Apr 2019 07:41:12 +0000 (+0900) Subject: Merge branch 'sg/test-atexit' X-Git-Tag: v2.22.0-rc0~73 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=579b75ad9530827fe00740b8551963f16f279c40;p=thirdparty%2Fgit.git Merge branch 'sg/test-atexit' Test framework update to more robustly clean up leftover files and processes after tests are done. * sg/test-atexit: t9811-git-p4-label-import: fix pipeline negation git p4 test: disable '-x' tracing in the p4d watchdog loop git p4 test: simplify timeout handling git p4 test: clean up the p4d cleanup functions git p4 test: use 'test_atexit' to kill p4d and the watchdog process t0301-credential-cache: use 'test_atexit' to stop the credentials helper tests: use 'test_atexit' to stop httpd git-daemon: use 'test_atexit` to stop 'git-daemon' test-lib: introduce 'test_atexit' t/lib-git-daemon: make sure to kill the 'git-daemon' process test-lib: fix interrupt handling with 'dash' and '--verbose-log -x' --- 579b75ad9530827fe00740b8551963f16f279c40 diff --cc t/t5550-http-fetch-dumb.sh index 694b77c855,57f6f8c628..b811d89cfd --- a/t/t5550-http-fetch-dumb.sh +++ b/t/t5550-http-fetch-dumb.sh @@@ -408,21 -408,4 +408,20 @@@ test_expect_success 'print HTTP error w test_i18ngrep "unable to access.*/redir-to/502" stderr ' +test_expect_success 'fetching via http alternates works' ' + parent=$HTTPD_DOCUMENT_ROOT_PATH/alt-parent.git && + git init --bare "$parent" && + git -C "$parent" --work-tree=. commit --allow-empty -m foo && + git -C "$parent" update-server-info && + commit=$(git -C "$parent" rev-parse HEAD) && + + child=$HTTPD_DOCUMENT_ROOT_PATH/alt-child.git && + git init --bare "$child" && + echo "../../alt-parent.git/objects" >"$child/objects/info/alternates" && + git -C "$child" update-ref HEAD $commit && + git -C "$child" update-server-info && + + git -c http.followredirects=true clone "$HTTPD_URL/dumb/alt-child.git" +' + - stop_httpd test_done