The bisection cleanup should be performed with bad merge base so that
the user can return to its original position with `git bisect reset`.
Mentored-by: Lars Schneider [off-list ref]
Mentored-by: Christian Couder [off-list ref]
Signed-off-by: Pranit Bauva <redacted>
---
t/t6030-bisect-porcelain.sh | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/t/t6030-bisect-porcelain.sh b/t/t6030-bisect-porcelain.sh
index e62e2a8..8ac77ee 100755
--- a/t/t6030-bisect-porcelain.sh
+++ b/t/t6030-bisect-porcelain.sh
@@ -911,4 +911,11 @@ test_expect_success 'git bisect reset cleans bisection state properly' '
test_path_is_missing "$GIT_DIR/BISECT_START"
'
+test_expect_success 'check whether bisection cleanup is not done with bad merges' '
+ git bisect start $HASH7 $SIDE_HASH7 &&
+ test_expect_failure git bisect bad >out 2>out &&
+ test_i18ngrep "The merge base" out &&
+ test -e .git/BISECT_START
+'
+
test_done
--
https://github.com/git/git/pull/287