]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Merge branch 'ps/ref-tests-update-more'
authorJunio C Hamano <gitster@pobox.com>
Wed, 20 Dec 2023 18:14:53 +0000 (10:14 -0800)
committerJunio C Hamano <gitster@pobox.com>
Wed, 20 Dec 2023 18:14:53 +0000 (10:14 -0800)
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

1  2 
t/t1400-update-ref.sh
t/t4013-diff-various.sh

index 6d1810c358ffaf9c592befe946183ce3a70f04a4,c41cd9b6bf91b2fece4e5139613f59584e882e8f..f18843bf7aa293d26ef1aabc7fbb8f2c1a8dca03
@@@ -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 &&
Simple merge