]> git.ipfire.org Git - thirdparty/git.git/commitdiff
git p4 test: check for error message in failed test
authorPete Wyckoff <pw@padd.com>
Wed, 27 Jun 2012 12:00:59 +0000 (08:00 -0400)
committerJunio C Hamano <gitster@pobox.com>
Thu, 28 Jun 2012 04:06:35 +0000 (21:06 -0700)
Make sure the test fails for the expected reason.

Signed-off-by: Pete Wyckoff <pw@padd.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t9800-git-p4-basic.sh

index 7401c215626fa95fa36b35f8ee2e247c8439c5ca..84676a114e54c76d52a59795ff332a0671daee8d 100755 (executable)
@@ -45,7 +45,8 @@ test_expect_success 'git p4 sync uninitialized repo' '
        test_when_finished cleanup_git &&
        (
                cd "$git" &&
-               test_must_fail git p4 sync
+               test_must_fail git p4 sync 2>errs &&
+               test_i18ngrep "Perhaps you never did" errs
        )
 '