diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-07-10 13:59:07 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-07-10 13:59:07 -0700 |
commit | 5a24b4e14a7120879213aad9a13b1914e5756820 (patch) | |
tree | 88d206f758fcbf18040e0129c94866a595138bfc | |
parent | Merge branch 'ab/sha1dc-maint' into maint (diff) | |
parent | t5534: fix misleading grep invocation (diff) | |
download | tgif-5a24b4e14a7120879213aad9a13b1914e5756820.tar.xz |
Merge branch 'js/t5534-rev-parse-gives-multi-line-output-fix' into maint
A few tests that tried to verify the contents of push certificates
did not use 'git rev-parse' to formulate the line to look for in
the certificate correctly.
* js/t5534-rev-parse-gives-multi-line-output-fix:
t5534: fix misleading grep invocation
-rwxr-xr-x | t/t5534-push-signed.sh | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/t/t5534-push-signed.sh b/t/t5534-push-signed.sh index 5bcb288f5c..464ffdd147 100755 --- a/t/t5534-push-signed.sh +++ b/t/t5534-push-signed.sh @@ -119,8 +119,11 @@ test_expect_success GPG 'signed push sends push certificate' ' sed -n -e "s/^nonce /NONCE=/p" -e "/^$/q" dst/push-cert ) >expect && - grep "$(git rev-parse noop ff) refs/heads/ff" dst/push-cert && - grep "$(git rev-parse noop noff) refs/heads/noff" dst/push-cert && + noop=$(git rev-parse noop) && + ff=$(git rev-parse ff) && + noff=$(git rev-parse noff) && + grep "$noop $ff refs/heads/ff" dst/push-cert && + grep "$noop $noff refs/heads/noff" dst/push-cert && test_cmp expect dst/push-cert-status ' @@ -200,8 +203,11 @@ test_expect_success GPG 'fail without key and heed user.signingkey' ' sed -n -e "s/^nonce /NONCE=/p" -e "/^$/q" dst/push-cert ) >expect && - grep "$(git rev-parse noop ff) refs/heads/ff" dst/push-cert && - grep "$(git rev-parse noop noff) refs/heads/noff" dst/push-cert && + noop=$(git rev-parse noop) && + ff=$(git rev-parse ff) && + noff=$(git rev-parse noff) && + grep "$noop $ff refs/heads/ff" dst/push-cert && + grep "$noop $noff refs/heads/noff" dst/push-cert && test_cmp expect dst/push-cert-status ' |