Merge branch 'sg/fast-import-dump-refs-on-checkpoint-fix'
authorJunio C Hamano <gitster@pobox.com>
Wed, 15 Aug 2018 22:08:20 +0000 (15:08 -0700)
committerJunio C Hamano <gitster@pobox.com>
Wed, 15 Aug 2018 22:08:20 +0000 (15:08 -0700)
Test update.

* sg/fast-import-dump-refs-on-checkpoint-fix:
t9300: wait for background fast-import process to die after killing it

1  2 
t/t9300-fast-import.sh
diff --combined t/t9300-fast-import.sh
index 9e7f96223dc2222c48b172711b4b469ff08190c8,950cfb18b9043ef126bd58ce15233eaf740f8806..fac33e524c760c5dedc908c02e2efc185eeed92a
@@@ -876,7 -876,7 +876,7 @@@ test_expect_success 'L: verify interna
        EXPECT_END
  
        git fast-import <input &&
 -      git diff-tree --abbrev --raw L^ L >output &&
 +      GIT_PRINT_SHA1_ELLIPSIS="yes" git diff-tree --abbrev --raw L^ L >output &&
        test_cmp expect output
  '
  
@@@ -1185,7 -1185,7 +1185,7 @@@ test_expect_success PIPE 'N: empty dire
        test_cmp expect.response response &&
        git rev-list read-empty |
        git diff-tree -r --root --stdin |
 -      sed "s/$_x40/OBJNAME/g" >actual &&
 +      sed "s/$OID_REGEX/OBJNAME/g" >actual &&
        test_cmp expect actual
  '
  
@@@ -1271,7 -1271,7 +1271,7 @@@ test_expect_success 'N: delete director
        git fast-import <input &&
        git rev-list N-delete |
                git diff-tree -r --stdin --root --always |
 -              sed -e "s/$_x40/OBJID/g" >actual &&
 +              sed -e "s/$OID_REGEX/OBJID/g" >actual &&
        test_cmp expect actual
  '
  
@@@ -2602,7 -2602,7 +2602,7 @@@ test_expect_success 'R: terminating "do
        EOF
        git rev-list done-ends |
        git diff-tree -r --stdin --root --always |
 -      sed -e "s/$_x40/OBJID/g" >actual &&
 +      sed -e "s/$OID_REGEX/OBJID/g" >actual &&
        test_cmp expect actual
  '
  
@@@ -2654,7 -2654,7 +2654,7 @@@ test_expect_success 'R: corrupt lines d
  ##
  test_expect_success 'R: blob bigger than threshold' '
        blobsize=$((2*1024*1024 + 53)) &&
 -      test-genrandom bar $blobsize >expect &&
 +      test-tool genrandom bar $blobsize >expect &&
        cat >input <<-INPUT_END &&
        commit refs/heads/big-file
        committer $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> $GIT_COMMITTER_DATE
@@@ -3147,7 -3147,10 +3147,10 @@@ background_import_then_checkpoint () 
        echo $! >V.pid
        # We don't mind if fast-import has already died by the time the test
        # ends.
-       test_when_finished "exec 8>&-; exec 9>&-; kill $(cat V.pid) || true"
+       test_when_finished "
+               exec 8>&-; exec 9>&-;
+               kill $(cat V.pid) && wait $(cat V.pid)
+               true"
  
        # Start in the background to ensure we adhere strictly to (blocking)
        # pipes writing sequence. We want to assume that the write below could