From mboxrd@z Thu Jan 1 00:00:00 1970 From: Vasco Almeida Subject: [PATCH v4 19/38] tests: unpack-trees: update to use test_i18n* functions Date: Tue, 7 Jun 2016 11:52:18 +0000 Message-ID: <1465300357-7557-20-git-send-email-vascomalmeida@sapo.pt> References: <1465300357-7557-1-git-send-email-vascomalmeida@sapo.pt> Cc: Vasco Almeida , Jiang Xin , =?UTF-8?q?=C3=86var=20Arnfj=C3=B6r=C3=B0=20Bjarmason?= , Sunshine , Junio C Hamano To: git@vger.kernel.org X-From: git-owner@vger.kernel.org Tue Jun 07 13:56:11 2016 Return-path: Envelope-to: gcvg-git-2@plane.gmane.org Received: from vger.kernel.org ([209.132.180.67]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1bAFc4-0000Ej-6H for gcvg-git-2@plane.gmane.org; Tue, 07 Jun 2016 13:56:04 +0200 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1161226AbcFGL4A (ORCPT ); Tue, 7 Jun 2016 07:56:00 -0400 Received: from relay3.ptmail.sapo.pt ([212.55.154.23]:33045 "EHLO sapo.pt" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S932855AbcFGLyq (ORCPT ); Tue, 7 Jun 2016 07:54:46 -0400 Received: (qmail 27959 invoked from network); 7 Jun 2016 11:54:44 -0000 Received: (qmail 18968 invoked from network); 7 Jun 2016 11:54:44 -0000 Received: from unknown (HELO localhost.localdomain) (vascomalmeida@sapo.pt@[85.246.157.91]) (envelope-sender ) by ptmail-mta-auth02 (qmail-ptmail-1.0.0) with ESMTPA for ; 7 Jun 2016 11:54:39 -0000 X-PTMail-RemoteIP: 85.246.157.91 X-PTMail-AllowedSender-Action: X-PTMail-Service: default X-Mailer: git-send-email 2.7.3 In-Reply-To: <1465300357-7557-1-git-send-email-vascomalmeida@sapo.pt> Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Archived-At: Use functions test_i18ncmp and test_i18ngrep to successfully pass tests running under GETTEXT_POISON. The output strings compared to in these test were marked for translation in ed47fdf ("i18n: unpack-trees: mark strings for translation", 2016-04-09) and later improved in 2e3926b ("i18n: unpack-trees: avoid substituting only a verb in sentences", 2016-05-12). Signed-off-by: Vasco Almeida --- t/t1011-read-tree-sparse-checkout.sh | 2 +- t/t3400-rebase.sh | 4 ++-- t/t3404-rebase-interactive.sh | 4 ++-- t/t7607-merge-overwrite.sh | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/t/t1011-read-tree-sparse-checkout.sh b/t/t1011-read-tree-sparse-checkout.sh index 0c74bee..3583105 100755 --- a/t/t1011-read-tree-sparse-checkout.sh +++ b/t/t1011-read-tree-sparse-checkout.sh @@ -247,7 +247,7 @@ error: The following untracked working tree files would be overwritten by checko Please move or remove them before you can switch branches. Aborting EOF - test_cmp expected actual + test_i18ncmp expected actual ' test_expect_success 'checkout without --ignore-skip-worktree-bits' ' diff --git a/t/t3400-rebase.sh b/t/t3400-rebase.sh index 47b5682..f5fd15e 100755 --- a/t/t3400-rebase.sh +++ b/t/t3400-rebase.sh @@ -136,8 +136,8 @@ test_expect_success 'setup: recover' ' test_expect_success 'Show verbose error when HEAD could not be detached' ' >B && test_must_fail git rebase topic 2>output.err >output.out && - grep "The following untracked working tree files would be overwritten by checkout:" output.err && - grep B output.err + test_i18ngrep "The following untracked working tree files would be overwritten by checkout:" output.err && + test_i18ngrep B output.err ' rm -f B diff --git a/t/t3404-rebase-interactive.sh b/t/t3404-rebase-interactive.sh index f4ccd10..8ac1868 100755 --- a/t/t3404-rebase-interactive.sh +++ b/t/t3404-rebase-interactive.sh @@ -219,9 +219,9 @@ test_expect_success 'abort with error when new base cannot be checked out' ' git commit -m "remove file in base" && set_fake_editor && test_must_fail git rebase -i master > output 2>&1 && - grep "The following untracked working tree files would be overwritten by checkout:" \ + test_i18ngrep "The following untracked working tree files would be overwritten by checkout:" \ output && - grep "file1" output && + test_i18ngrep "file1" output && test_path_is_missing .git/rebase-merge && git reset --hard HEAD^ ' diff --git a/t/t7607-merge-overwrite.sh b/t/t7607-merge-overwrite.sh index 758a623..e8ec54c 100755 --- a/t/t7607-merge-overwrite.sh +++ b/t/t7607-merge-overwrite.sh @@ -125,7 +125,7 @@ test_expect_success 'will not overwrite untracked file in leading path' ' cp important sub && cp important sub2 && test_must_fail git merge sub 2>out && - test_cmp out expect && + test_i18ncmp out expect && test_path_is_missing .git/MERGE_HEAD && test_cmp important sub && test_cmp important sub2 && -- 2.7.3