3 test_description
='rebase behavior when on-disk files are broken'
6 test_expect_success
'set up conflicting branches' '
7 test_commit base file &&
8 git checkout -b branch1 &&
9 test_commit one file &&
10 git checkout -b branch2 HEAD^ &&
15 test_when_finished
"git rebase --abort" &&
16 git checkout
-B tmp branch2
&&
17 test_must_fail git rebase branch1
20 check_resolve_fails
() {
21 echo resolved
>file &&
23 test_must_fail git rebase
--continue
26 for item
in NAME EMAIL DATE
28 test_expect_success
"detect missing GIT_AUTHOR_$item" '
31 grep -v $item .git/rebase-merge/author-script >tmp &&
32 mv tmp .git/rebase-merge/author-script &&
38 for item
in NAME EMAIL DATE
40 test_expect_success
"detect duplicate GIT_AUTHOR_$item" '
43 grep -i $item .git/rebase-merge/author-script >tmp &&
44 cat tmp >>.git/rebase-merge/author-script &&
50 test_expect_success
'unknown key in author-script' '
53 echo "GIT_AUTHOR_BOGUS=${SQ}whatever${SQ}" \
54 >>.git/rebase-merge/author-script &&