@ -581,5 +581,53 @@ test_expect_success 'erroring out when using bad path parameters' '
@@ -581,5 +581,53 @@ test_expect_success 'erroring out when using bad path parameters' '
'
#
# This creates a broken branch which cannot be checked out because
# the tree created has been deleted.
#
# H1-H2-H3-H4-H5-H6-H7 <--other
# \
# S5-S6'-S7'-S8'-S9 <--broken
#
# Commits marked with ' have a missing tree.
#
test_expect_success 'broken branch creation' '
git bisect reset &&
git checkout -b broken $HASH4 &&
git tag BROKEN_HASH4 $HASH4 &&
add_line_into_file "5(broken): first line on a broken branch" hello2 &&
git tag BROKEN_HASH5 &&
mkdir missing &&
:> missing/MISSING &&
git add missing/MISSING &&
git commit -m "6(broken): Added file that will be deleted"
git tag BROKEN_HASH6 &&
add_line_into_file "7(broken): second line on a broken branch" hello2 &&
git tag BROKEN_HASH7 &&
add_line_into_file "8(broken): third line on a broken branch" hello2 &&