diff options
Diffstat (limited to 't/t5411/test-0027-push-options--porcelain.sh')
-rw-r--r-- | t/t5411/test-0027-push-options--porcelain.sh | 22 |
1 files changed, 8 insertions, 14 deletions
diff --git a/t/t5411/test-0027-push-options--porcelain.sh b/t/t5411/test-0027-push-options--porcelain.sh index 3a6561b5ea..447fbfec0c 100644 --- a/t/t5411/test-0027-push-options--porcelain.sh +++ b/t/t5411/test-0027-push-options--porcelain.sh @@ -17,16 +17,14 @@ test_expect_success "proc-receive: not support push options ($PROTOCOL/porcelain -o reviewer=user1 \ origin \ HEAD:refs/for/main/topic \ - >out 2>&1 && - make_user_friendly_and_stable_output <out >actual && + >out-$test_count 2>&1 && + make_user_friendly_and_stable_output <out-$test_count >actual && test_i18ngrep "fatal: the receiving end does not support push options" \ actual && - git -C "$upstream" show-ref >out && - make_user_friendly_and_stable_output <out >actual && - cat >expect <<-EOF && + + test_cmp_refs -C "$upstream" <<-EOF <COMMIT-A> refs/heads/main EOF - test_cmp expect actual ' test_expect_success "enable push options ($PROTOCOL/porcelain)" ' @@ -72,13 +70,11 @@ test_expect_success "proc-receive: ignore push-options for version 0 ($PROTOCOL/ Done EOF test_cmp expect actual && - git -C "$upstream" show-ref >out && - make_user_friendly_and_stable_output <out >actual && - cat >expect <<-EOF && + + test_cmp_refs -C "$upstream" <<-EOF <COMMIT-A> refs/heads/main <COMMIT-A> refs/heads/next EOF - test_cmp expect actual ' test_expect_success "restore proc-receive hook ($PROTOCOL/porcelain)" ' @@ -128,13 +124,11 @@ test_expect_success "proc-receive: push with options ($PROTOCOL/porcelain)" ' Done EOF test_cmp expect actual && - git -C "$upstream" show-ref >out && - make_user_friendly_and_stable_output <out >actual && - cat >expect <<-EOF && + + test_cmp_refs -C "$upstream" <<-EOF <COMMIT-A> refs/heads/main <COMMIT-A> refs/heads/next EOF - test_cmp expect actual ' # Refs of upstream : main(A) next(A) |