Skip to content

Commit

Permalink
rebase -i: test "Nothing to do" case with autostash
Browse files Browse the repository at this point in the history
Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Matthieu Moy authored and Junio C Hamano committed May 20, 2014
1 parent e4244eb commit ddb5432
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions t/t3420-rebase-autostash.sh
Original file line number Diff line number Diff line change
Expand Up @@ -167,4 +167,19 @@ testrebase "" .git/rebase-apply
testrebase " --merge" .git/rebase-merge
testrebase " --interactive" .git/rebase-merge

test_expect_success 'abort rebase -i with --autostash' '
test_when_finished "git reset --hard" &&
echo uncommited-content >file0 &&
(
write_script abort-editor.sh <<-\EOF &&
echo >"$1"
EOF
test_set_editor "$(pwd)/abort-editor.sh" &&
test_must_fail git rebase -i --autostash HEAD^ &&
rm -f abort-editor.sh
) &&
echo uncommited-content >expected &&
test_cmp expected file0
'

test_done

0 comments on commit ddb5432

Please sign in to comment.