From: David Aguilar <davvid@gmail.com>
To: gitster@pobox.com
Cc: sschuberth@gmail.com, git@vger.kernel.org
Subject: [PATCH v2] t7800-difftool.sh: Test mergetool.prompt fallback
Date: Fri, 22 Jan 2010 22:03:36 -0800 [thread overview]
Message-ID: <1264226616-19019-1-git-send-email-davvid@gmail.com> (raw)
4cacc621 made difftool fall back to mergetool.prompt
when difftool.prompt is unconfigured. This adds a test.
Signed-off-by: David Aguilar <davvid@gmail.com>
---
Oops, the last one had a typo in the test string.
t/t7800-difftool.sh | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/t/t7800-difftool.sh b/t/t7800-difftool.sh
index fad5472..19c72f5 100755
--- a/t/t7800-difftool.sh
+++ b/t/t7800-difftool.sh
@@ -27,6 +27,7 @@ remove_config_vars()
git config --unset difftool.prompt
git config --unset merge.tool
git config --unset mergetool.test-tool.cmd
+ git config --unset mergetool.prompt
return 0
}
@@ -159,6 +160,17 @@ test_expect_success 'difftool.prompt config variable is false' '
restore_test_defaults
'
+# Test that we don't have to pass --no-prompt when mergetool.prompt is false
+test_expect_success 'difftool merge.prompt = false' '
+ git config --unset difftool.prompt
+ git config mergetool.prompt false &&
+
+ diff=$(git difftool branch) &&
+ test "$diff" = "branch" &&
+
+ restore_test_defaults
+'
+
# Test that the -y flag can override difftool.prompt = true
test_expect_success 'difftool.prompt can overridden with -y' '
git config difftool.prompt true &&
--
1.6.6.1.436.gaba7d.dirty
reply other threads:[~2010-01-23 6:03 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1264226616-19019-1-git-send-email-davvid@gmail.com \
--to=davvid@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=sschuberth@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).