]> git.ipfire.org Git - thirdparty/git.git/commitdiff
t3419: stop losing return code of git command
authorDenton Liu <liu.denton@gmail.com>
Tue, 7 Jan 2020 04:53:09 +0000 (23:53 -0500)
committerJunio C Hamano <gitster@pobox.com>
Mon, 27 Jan 2020 20:56:02 +0000 (12:56 -0800)
Fix invocation of git command so its exit codes is not lost within
a non-assignment command substitution.

Signed-off-by: Denton Liu <liu.denton@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t3419-rebase-patch-id.sh

index 49f548cdb93d53d88723adcd1f414a4db4c14a73..94552669ae87c9480afa004e2655729e9450d8e6 100755 (executable)
@@ -80,7 +80,8 @@ do_tests () {
                git commit -q -m "change big file again" &&
                git checkout -q other^{} &&
                git rebase master &&
-               test_must_fail test -n "$(git rev-list master...HEAD~)"
+               git rev-list master...HEAD~ >revs &&
+               test_must_be_empty revs
        '
 
        test_expect_success $pr 'do not drop patch' '