From d492b31cafe9aa5ce001b1d48815f4c0bb40d01a Mon Sep 17 00:00:00 2001 From: Stephan Beyer Date: Sat, 12 Jul 2008 17:47:52 +0200 Subject: t/: Use "test_must_fail git" instead of "! git" This patch changes every occurrence of "! git" -- with the meaning that a git call has to gracefully fail -- into "test_must_fail git". This is useful to - make sure the test does not fail because of a signal, e.g. SIGSEGV, and - advertise the use of "test_must_fail" for new tests. Signed-off-by: Stephan Beyer Signed-off-by: Junio C Hamano --- t/t3403-rebase-skip.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 't/t3403-rebase-skip.sh') diff --git a/t/t3403-rebase-skip.sh b/t/t3403-rebase-skip.sh index 0a26099658..0d33c71daa 100755 --- a/t/t3403-rebase-skip.sh +++ b/t/t3403-rebase-skip.sh @@ -32,7 +32,7 @@ test_expect_success setup ' ' test_expect_success 'rebase with git am -3 (default)' ' - ! git rebase master + test_must_fail git rebase master ' test_expect_success 'rebase --skip with am -3' ' @@ -43,7 +43,7 @@ test_expect_success 'rebase moves back to skip-reference' ' test refs/heads/skip-reference = $(git symbolic-ref HEAD) && git branch post-rebase && git reset --hard pre-rebase && - ! git rebase master && + test_must_fail git rebase master && echo "hello" > hello && git add hello && git rebase --continue && @@ -53,7 +53,9 @@ test_expect_success 'rebase moves back to skip-reference' ' test_expect_success 'checkout skip-merge' 'git checkout -f skip-merge' -test_expect_success 'rebase with --merge' '! git rebase --merge master' +test_expect_success 'rebase with --merge' ' + test_must_fail git rebase --merge master +' test_expect_success 'rebase --skip with --merge' ' git rebase --skip -- cgit v1.2.3