summaryrefslogtreecommitdiff
path: root/t/t4209-log-pickaxe.sh
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2021-04-12 17:15:12 (GMT)
committerJunio C Hamano <gitster@pobox.com>2021-05-11 03:47:31 (GMT)
commit064952fc34b9765282fec057b3af260eae7c75c6 (patch)
treef6db56d1aa6c917c75de8590f8a6b4e6405a6f94 /t/t4209-log-pickaxe.sh
parent69ae93089cd892d70429f7f06371860d65cb1f1b (diff)
downloadgit-064952fc34b9765282fec057b3af260eae7c75c6.zip
git-064952fc34b9765282fec057b3af260eae7c75c6.tar.gz
git-064952fc34b9765282fec057b3af260eae7c75c6.tar.bz2
pickaxe tests: test for -G, -S and --find-object incompatibility
Add a test for the options sanity check added in 5e505257f2 (diff: properly error out when combining multiple pickaxe options, 2018-01-04). Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4209-log-pickaxe.sh')
-rwxr-xr-xt/t4209-log-pickaxe.sh11
1 files changed, 11 insertions, 0 deletions
diff --git a/t/t4209-log-pickaxe.sh b/t/t4209-log-pickaxe.sh
index 9fa770b..21e22af 100755
--- a/t/t4209-log-pickaxe.sh
+++ b/t/t4209-log-pickaxe.sh
@@ -55,6 +55,17 @@ test_expect_success setup '
git rev-parse --verify HEAD >expect_second
'
+test_expect_success 'usage' '
+ test_expect_code 128 git log -Gregex -Sstring 2>err &&
+ grep "mutually exclusive" err &&
+
+ test_expect_code 128 git log -Gregex --find-object=HEAD 2>err &&
+ grep "mutually exclusive" err &&
+
+ test_expect_code 128 git log -Sstring --find-object=HEAD 2>err &&
+ grep "mutually exclusive" err
+'
+
test_log expect_initial --grep initial
test_log expect_nomatch --grep InItial
test_log_icase expect_initial --grep InItial