summaryrefslogtreecommitdiff
path: root/t/t7800-difftool.sh
diff options
context:
space:
mode:
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>2019-01-27 00:35:24 (GMT)
committerJunio C Hamano <gitster@pobox.com>2019-01-28 00:28:17 (GMT)
commitbaa4adc66aefe2c3cc15b573b8a19dec786a1641 (patch)
treec070957142913b008595683d14f1fdeea3246cba /t/t7800-difftool.sh
parent202fbb33156287feeabc39c46db0e9857cb97152 (diff)
downloadgit-baa4adc66aefe2c3cc15b573b8a19dec786a1641.zip
git-baa4adc66aefe2c3cc15b573b8a19dec786a1641.tar.gz
git-baa4adc66aefe2c3cc15b573b8a19dec786a1641.tar.bz2
parse-options: disable option abbreviation with PARSE_OPT_KEEP_UNKNOWN
parse-options can unambiguously find an abbreviation only if it sees all available options. This is usually the case when you use parse_options(). But there are other callers like blame or shortlog which uses parse_options_start() in combination with a custom option parser, like rev-list. parse-options cannot see all options in this case and will get abbrev detection wrong. Disable it. t7800 needs update because --symlink no longer expands to --symlinks and will be passed down to git-diff, which will not recognize it. I still think this is the correct thing to do. But if --symlink has been actually used in the wild, we would just add an option alias for it. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7800-difftool.sh')
-rwxr-xr-xt/t7800-difftool.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/t/t7800-difftool.sh b/t/t7800-difftool.sh
index 22b9199..bb9a7f4 100755
--- a/t/t7800-difftool.sh
+++ b/t/t7800-difftool.sh
@@ -546,7 +546,7 @@ do
done >actual
EOF
-test_expect_success SYMLINKS 'difftool --dir-diff --symlink without unstaged changes' '
+test_expect_success SYMLINKS 'difftool --dir-diff --symlinks without unstaged changes' '
cat >expect <<-EOF &&
file
$PWD/file
@@ -555,7 +555,7 @@ test_expect_success SYMLINKS 'difftool --dir-diff --symlink without unstaged cha
sub/sub
$PWD/sub/sub
EOF
- git difftool --dir-diff --symlink \
+ git difftool --dir-diff --symlinks \
--extcmd "./.git/CHECK_SYMLINKS" branch HEAD &&
test_cmp expect actual
'