From: Matthieu Moy Date: Tue, 20 May 2014 07:49:31 +0000 (+0200) Subject: rebase -i: test "Nothing to do" case with autostash X-Git-Tag: v2.0.1~5^2 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/ddb5432d2390e1957e473618009ba3d2fbbf29a7?hp=--cc rebase -i: test "Nothing to do" case with autostash Signed-off-by: Matthieu Moy Signed-off-by: Junio C Hamano --- ddb5432d2390e1957e473618009ba3d2fbbf29a7 diff --git a/t/t3420-rebase-autostash.sh b/t/t3420-rebase-autostash.sh index 90eb26493c..d783f03d3f 100755 --- a/t/t3420-rebase-autostash.sh +++ b/t/t3420-rebase-autostash.sh @@ -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