summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2010-06-21 06:02:47 -0700
committerJunio C Hamano <gitster@pobox.com>2010-06-21 06:02:47 -0700
commitd4f8f74bc6cf8c5851f67d46c49b6e2c8fea601b (patch)
tree7a86c027c772b0670302218ff6ccea60a8835e87 /t
parent1a5296cb92691c5656bbc6aacaf49ca31b1ee8c0 (diff)
parentcddb42d2c58a9de9b2b5ef68817778e7afaace3e (diff)
downloadgit-d4f8f74bc6cf8c5851f67d46c49b6e2c8fea601b.tar.gz
Merge branch 'jn/document-rebase-i-p-limitation'
* jn/document-rebase-i-p-limitation: rebase -i -p: document shortcomings
Diffstat (limited to 't')
-rwxr-xr-xt/t3404-rebase-interactive.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/t/t3404-rebase-interactive.sh b/t/t3404-rebase-interactive.sh
index f20ea38411..6668907ec5 100755
--- a/t/t3404-rebase-interactive.sh
+++ b/t/t3404-rebase-interactive.sh
@@ -181,6 +181,12 @@ test_expect_success '-p handles "no changes" gracefully' '
test $HEAD = $(git rev-parse HEAD)
'
+test_expect_failure 'exchange two commits with -p' '
+ FAKE_LINES="2 1" git rebase -i -p HEAD~2 &&
+ test H = $(git cat-file commit HEAD^ | sed -ne \$p) &&
+ test G = $(git cat-file commit HEAD | sed -ne \$p)
+'
+
test_expect_success 'preserve merges with -p' '
git checkout -b to-be-preserved master^ &&
: > unrelated-file &&