Merge branch 'sg/test-atexit'
authorJunio C Hamano <gitster@pobox.com>
Thu, 25 Apr 2019 07:41:12 +0000 (16:41 +0900)
committerJunio C Hamano <gitster@pobox.com>
Thu, 25 Apr 2019 07:41:12 +0000 (16:41 +0900)
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'

1  2 
t/README
t/t5500-fetch-pack.sh
t/t5539-fetch-http-shallow.sh
t/t5541-http-push-smart.sh
t/t5550-http-fetch-dumb.sh
t/t5551-http-fetch-smart.sh
t/t5601-clone.sh
t/t5700-protocol-v1.sh
t/test-lib-functions.sh
t/test-lib.sh
diff --cc t/README
Simple merge
Simple merge
Simple merge
Simple merge
index 694b77c8556d45ca594375683b1fd2209a346947,57f6f8c6286774815e00e038a9683e0afafbe409..b811d89cfd6df25fb2e42db6f05a69cf0b7a6c3b
@@@ -408,21 -408,4 +408,20 @@@ test_expect_success 'print HTTP error w
        test_i18ngrep "unable to access.*/redir-to/502" stderr
  '
  
- stop_httpd
 +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"
 +'
 +
  test_done
Simple merge
Simple merge
Simple merge
Simple merge
diff --cc t/test-lib.sh
Simple merge