aboutsummaryrefslogtreecommitdiffstats
path: root/t/t3404-rebase-interactive.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2024-02-14 15:36:05 -0800
committerJunio C Hamano <gitster@pobox.com>2024-02-14 15:36:05 -0800
commitc036a145c380e79db5fab5aafb87c4981e11cc9e (patch)
treea96c28427f19085e4bed0477020057cc3bd64175 /t/t3404-rebase-interactive.sh
parent09e0aa64b3fbdc6df541cd2beefe70170f038252 (diff)
parente4301f73fffacf2ba9fb2042b95de32880381e72 (diff)
downloadgit-c036a145c380e79db5fab5aafb87c4981e11cc9e.tar.gz
Merge branch 'vn/rebase-with-cherry-pick-authorship'
"git cherry-pick" invoked during "git rebase -i" session lost the authorship information, which has been corrected. * vn/rebase-with-cherry-pick-authorship: sequencer: unset GIT_CHERRY_PICK_HELP for 'exec' commands
Diffstat (limited to 't/t3404-rebase-interactive.sh')
-rwxr-xr-xt/t3404-rebase-interactive.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/t/t3404-rebase-interactive.sh b/t/t3404-rebase-interactive.sh
index 64b641002e..d1bead61fa 100755
--- a/t/t3404-rebase-interactive.sh
+++ b/t/t3404-rebase-interactive.sh
@@ -153,6 +153,18 @@ test_expect_success 'rebase -i with the exec command checks tree cleanness' '
git rebase --continue
'
+test_expect_success 'cherry-pick works with rebase --exec' '
+ test_when_finished "git cherry-pick --abort; \
+ git rebase --abort; \
+ git checkout primary" &&
+ echo "exec git cherry-pick G" >todo &&
+ (
+ set_replace_editor todo &&
+ test_must_fail git rebase -i D D
+ ) &&
+ test_cmp_rev G CHERRY_PICK_HEAD
+'
+
test_expect_success 'rebase -x with empty command fails' '
test_when_finished "git rebase --abort ||:" &&
test_must_fail env git rebase -x "" @ 2>actual &&