summaryrefslogtreecommitdiff
path: root/t/t5411/test-0001-standard-git-push--porcelain.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2020-11-25 23:24:52 (GMT)
committerJunio C Hamano <gitster@pobox.com>2020-11-25 23:24:52 (GMT)
commit8f8f10ac09fff0d15b74f8bded18a81d24f0127d (patch)
tree119ac744c0e9ecccb06a18802b40eb52ac43efa0 /t/t5411/test-0001-standard-git-push--porcelain.sh
parent455e8d18f81583d0270685edc6ec2ed201fc984c (diff)
parent80ffeb94f4c9eae4e099fec47e39105fc1e19132 (diff)
downloadgit-8f8f10ac09fff0d15b74f8bded18a81d24f0127d.zip
git-8f8f10ac09fff0d15b74f8bded18a81d24f0127d.tar.gz
git-8f8f10ac09fff0d15b74f8bded18a81d24f0127d.tar.bz2
Merge branch 'jx/t5411-flake-fix'
The exchange between receive-pack and proc-receive hook did not carefully check for errors. * jx/t5411-flake-fix: receive-pack: use default version 0 for proc-receive receive-pack: gently write messages to proc-receive t5411: new helper filter_out_user_friendly_and_stable_output
Diffstat (limited to 't/t5411/test-0001-standard-git-push--porcelain.sh')
-rw-r--r--t/t5411/test-0001-standard-git-push--porcelain.sh15
1 files changed, 7 insertions, 8 deletions
diff --git a/t/t5411/test-0001-standard-git-push--porcelain.sh b/t/t5411/test-0001-standard-git-push--porcelain.sh
index 747307f..bbead12 100644
--- a/t/t5411/test-0001-standard-git-push--porcelain.sh
+++ b/t/t5411/test-0001-standard-git-push--porcelain.sh
@@ -37,16 +37,15 @@ test_expect_success "git-push --atomic ($PROTOCOL/porcelain)" '
main \
$B:refs/heads/next \
>out 2>&1 &&
- make_user_friendly_and_stable_output <out |
- sed -n \
- -e "s/^# GETTEXT POISON #//" \
- -e "/^To / { s/ */ /g; p; }" \
- -e "/^! / { s/ */ /g; p; }" \
- >actual &&
+ filter_out_user_friendly_and_stable_output \
+ -e "s/^# GETTEXT POISON #//" \
+ -e "/^To / { p; }" \
+ -e "/^! / { p; }" \
+ <out >actual &&
cat >expect <<-EOF &&
To <URL/of/upstream.git>
- ! refs/heads/main:refs/heads/main [rejected] (non-fast-forward)
- ! <COMMIT-B>:refs/heads/next [rejected] (atomic push failed)
+ ! refs/heads/main:refs/heads/main [rejected] (non-fast-forward)
+ ! <COMMIT-B>:refs/heads/next [rejected] (atomic push failed)
EOF
test_cmp expect actual &&
git -C "$upstream" show-ref >out &&