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
This commit is contained in:
Junio C Hamano
2023-12-20 10:14:53 -08:00
10 changed files with 74 additions and 45 deletions

View File

@ -178,32 +178,29 @@ process_diffs () {
V=$(git version | sed -e 's/^git version //' -e 's/\./\\./g')
while read magic cmd
do
status=success
case "$magic" in
'' | '#'*)
continue ;;
:*)
magic=${magic#:}
:noellipses)
magic=noellipses
label="$magic-$cmd"
case "$magic" in
noellipses) ;;
failure)
status=failure
magic=
label="$cmd" ;;
*)
BUG "unknown magic $magic" ;;
esac ;;
;;
:*)
BUG "unknown magic $magic"
;;
*)
cmd="$magic $cmd" magic=
label="$cmd" ;;
cmd="$magic $cmd"
magic=
label="$cmd"
;;
esac
test=$(echo "$label" | sed -e 's|[/ ][/ ]*|_|g')
pfx=$(printf "%04d" $test_count)
expect="$TEST_DIRECTORY/t4013/diff.$test"
actual="$pfx-diff.$test"
test_expect_$status "git $cmd # magic is ${magic:-(not used)}" '
test_expect_success "git $cmd # magic is ${magic:-(not used)}" '
{
echo "$ git $cmd"
case "$magic" in