From: Vasco Almeida <vascomalmeida@sapo.pt>
To: git@vger.kernel.org
Cc: "Vasco Almeida" <vascomalmeida@sapo.pt>,
"Nguyễn Thái Ngọc Duy" <pclouds@gmail.com>
Subject: [PATCH] t5510: become resilient to GETTEXT_POISON
Date: Mon, 25 Jul 2016 09:31:08 +0000 [thread overview]
Message-ID: <1469439068-2724-1-git-send-email-vascomalmeida@sapo.pt> (raw)
Replace gettext poison text with appropriate values to be able to cut
the right output of git fetch command for comparison.
The first gettext poison falls from the previous line into the next
because the poison does not add a newline, so we must replace it with
nothing.
Signed-off-by: Vasco Almeida <vascomalmeida@sapo.pt>
---
t/t5510-fetch.sh | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/t/t5510-fetch.sh b/t/t5510-fetch.sh
index 6bd4853..b261223 100755
--- a/t/t5510-fetch.sh
+++ b/t/t5510-fetch.sh
@@ -694,7 +694,10 @@ test_expect_success 'fetch aligned output' '
(
cd full-output &&
git -c fetch.output=full fetch origin 2>&1 | \
- grep -e "->" | cut -c 22- >../actual
+ grep -e "->" | \
+ sed -e "/master/ s/# GETTEXT POISON #//" \
+ -e "/tag/ s/# GETTEXT POISON #/[new tag] /" | \
+ cut -c 22- >../actual
) &&
cat >expect <<-\EOF &&
master -> origin/master
@@ -709,7 +712,10 @@ test_expect_success 'fetch compact output' '
(
cd compact &&
git -c fetch.output=compact fetch origin 2>&1 | \
- grep -e "->" | cut -c 22- >../actual
+ grep -e "->" | \
+ sed -e "/master/ s/# GETTEXT POISON #//" \
+ -e "/extraa/ s/# GETTEXT POISON #/[new tag] /" | \
+ cut -c 22- >../actual
) &&
cat >expect <<-\EOF &&
master -> origin/*
--
2.7.4
next reply other threads:[~2016-07-25 9:33 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-25 9:31 Vasco Almeida [this message]
2016-07-25 15:16 ` [PATCH] t5510: become resilient to GETTEXT_POISON Junio C Hamano
2016-07-25 16:07 ` Duy Nguyen
2016-07-26 12:58 ` [PATCH] t5510: skip tests under GETTEXT_POISON build Vasco Almeida
2016-07-26 16:53 ` Junio C Hamano
2016-07-26 20:11 ` Ævar Arnfjörð Bjarmason
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1469439068-2724-1-git-send-email-vascomalmeida@sapo.pt \
--to=vascomalmeida@sapo.pt \
--cc=git@vger.kernel.org \
--cc=pclouds@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).