git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Aguilar <davvid@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org, Adri Farr <14farresa@gmail.com>,
	Johannes Sixt <j6t@kdbg.org>,
	Sitaram Chamarty <sitaramc@gmail.com>
Subject: [PATCH v3 1/2] t7800-difftool: use "test_must_fail grep" instead of "! grep"
Date: Sun, 26 Oct 2014 18:15:41 -0700	[thread overview]
Message-ID: <1414372542-3485-1-git-send-email-davvid@gmail.com> (raw)
In-Reply-To: <544CAC30.7000607@kdbg.org>

Signed-off-by: David Aguilar <davvid@gmail.com>
---
This patch is new since v2.

This series now depends on "difftool--helper: exit when reading a prompt answer fails".

 t/t7800-difftool.sh | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/t/t7800-difftool.sh b/t/t7800-difftool.sh
index 9cf5dc9..b5b7f62 100755
--- a/t/t7800-difftool.sh
+++ b/t/t7800-difftool.sh
@@ -288,8 +288,8 @@ test_expect_success PERL 'say no to the first file' '
 	git difftool -x cat branch <input >output &&
 	grep m2 output &&
 	grep br2 output &&
-	! grep master output &&
-	! grep branch output
+	test_must_fail grep master output &&
+	test_must_fail grep branch output
 '
 
 test_expect_success PERL 'say no to the second file' '
@@ -297,16 +297,16 @@ test_expect_success PERL 'say no to the second file' '
 	git difftool -x cat branch <input >output &&
 	grep master output &&
 	grep branch output &&
-	! grep m2 output &&
-	! grep br2 output
+	test_must_fail grep m2 output &&
+	test_must_fail grep br2 output
 '
 
 test_expect_success PERL 'ending prompt input with EOF' '
 	git difftool -x cat branch </dev/null >output &&
-	! grep master output &&
-	! grep branch output &&
-	! grep m2 output &&
-	! grep br2 output
+	test_must_fail grep master output &&
+	test_must_fail grep branch output &&
+	test_must_fail grep m2 output &&
+	test_must_fail grep br2 output
 '
 
 test_expect_success PERL 'difftool --tool-help' '
-- 
2.1.2.557.g1025af0

  parent reply	other threads:[~2014-10-27  1:15 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-26  8:09 difftool--helper: exit when reading a prompt answer fails Johannes Sixt
2014-10-27  0:41 ` David Aguilar
2014-10-27  1:10   ` David Aguilar
2014-10-27 12:54     ` Michael J Gruber
2014-10-27 17:38   ` Junio C Hamano
2014-10-27  1:15 ` David Aguilar [this message]
2014-10-27  1:15   ` [PATCH v3 2/2] difftool: add support for --trust-exit-code David Aguilar
2014-10-27 18:45     ` Junio C Hamano
2014-10-28  9:34       ` David Aguilar

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=1414372542-3485-1-git-send-email-davvid@gmail.com \
    --to=davvid@gmail.com \
    --cc=14farresa@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=j6t@kdbg.org \
    --cc=sitaramc@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).