提交 27ccd8d1 编写于 作者: J Johannes Sixt 提交者: Junio C Hamano

t3404: begin "exchange commits with -p" test with correct preconditions

The test case shows a bug in 'rebase -p', but even if the bug were fixed
the test would fail because it did not ensure that the preconditions match
the postconditions that were checked. Insert the suitable 'git checkout'.
Signed-off-by: NJohannes Sixt <j6t@kdbg.org>
Acked-by: NJonathan Nieder <jrnieder@gmail.com>
Signed-off-by: NJunio C Hamano <gitster@pobox.com>
上级 042e9f94
......@@ -247,6 +247,7 @@ test_expect_success '-p handles "no changes" gracefully' '
'
test_expect_failure 'exchange two commits with -p' '
git checkout H &&
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)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册