aboutsummaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJohannes Schindelin <Johannes.Schindelin@gmx.de>2007-11-08 18:19:08 +0000
committerJunio C Hamano <gitster@pobox.com>2007-11-09 01:30:31 -0800
commit6fd2f5e60d4d574ff9e5dd8ce1e229328c785d69 (patch)
tree8f8845588cab44b7ad392ce52fb89316ad1c5600 /t
parentc238dad407aec1ccf6e364f9c95e10e7f84eac8f (diff)
downloadgit-6fd2f5e60d4d574ff9e5dd8ce1e229328c785d69.tar.gz
git-6fd2f5e60d4d574ff9e5dd8ce1e229328c785d69.tar.xz
rebase: operate on a detached HEAD
The interactive version of rebase does all the operations on a detached HEAD, so that after a successful rebase, <branch>@{1} is the pre-rebase state. The reflogs of "HEAD" still show all the actions in detail. This teaches the non-interactive version to do the same. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-xt/t3402-rebase-merge.sh7
1 files changed, 6 insertions, 1 deletions
diff --git a/t/t3402-rebase-merge.sh b/t/t3402-rebase-merge.sh
index 0779aaa9a..7b7d07269 100755
--- a/t/t3402-rebase-merge.sh
+++ b/t/t3402-rebase-merge.sh
@@ -48,9 +48,14 @@ test_expect_success 'reference merge' '
git merge -s recursive "reference merge" HEAD master
'
+PRE_REBASE=$(git rev-parse test-rebase)
test_expect_success rebase '
git checkout test-rebase &&
- git rebase --merge master
+ GIT_TRACE=1 git rebase --merge master
+'
+
+test_expect_success 'test-rebase@{1} is pre rebase' '
+ test $PRE_REBASE = $(git rev-parse test-rebase@{1})
'
test_expect_success 'merge and rebase should match' '