From: Junio C Hamano Date: Wed, 20 Dec 2023 18:14:53 +0000 (-0800) Subject: Merge branch 'ps/ref-tests-update-more' X-Git-Tag: v2.44.0-rc0~129 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a21a9296439cbbf548b87d820cd9de9ff81fea22;p=thirdparty%2Fgit.git Merge branch 'ps/ref-tests-update-more' Tests update. * ps/ref-tests-update-more: t6301: write invalid object ID via `test-tool ref-store` t5551: stop writing packed-refs directly t5401: speed up creation of many branches t4013: simplify magic parsing and drop "failure" t3310: stop checking for reference existence via `test -f` t1417: make `reflog --updateref` tests backend agnostic t1410: use test-tool to create empty reflog t1401: stop treating FETCH_HEAD as real reference t1400: split up generic reflog tests from the reffile-specific ones t0410: mark tests to require the reffiles backend --- a21a9296439cbbf548b87d820cd9de9ff81fea22 diff --cc t/t1400-update-ref.sh index 6d1810c358,c41cd9b6bf..f18843bf7a --- a/t/t1400-update-ref.sh +++ b/t/t1400-update-ref.sh @@@ -437,9 -447,24 +450,25 @@@ test_expect_success 'Query "main@{2005- test_grep -F "warning: log for ref $m unexpectedly ended on $ld" e ' -rm -f .git/$m .git/logs/$m expect +rm -f expect +git update-ref -d $m + test_expect_success REFFILES 'query reflog with gap' ' + test_when_finished "git update-ref -d $m" && + + git update-ref $m $F && + cat >.git/logs/$m <<-EOF && + $Z $A $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150320 -0500 + $A $B $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150380 -0500 + $D $F $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150680 -0500 + EOF + + git rev-parse --verify "main@{2005-05-26 23:33:01}" >actual 2>stderr && + echo "$B" >expect && + test_cmp expect actual && + test_grep -F "warning: log for ref $m has gap after $gd" stderr + ' + test_expect_success 'creating initial files' ' test_when_finished rm -f M && echo TEST >F &&