summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2021-09-03 13:49:29 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2021-09-03 13:49:29 -0700
commit77b063cd3528c10ec10614a4467dce8baab55dce (patch)
treea23b4f6fe70eda5709947d47354393e0df89a31e /t
parentMerge branch 'pw/rebase-r-fixes' (diff)
parentcompletion: bash: add correct suffix in variables (diff)
downloadtgif-77b063cd3528c10ec10614a4467dce8baab55dce.tar.xz
Merge branch 'fc/completion-updates'
Command line completion updates. * fc/completion-updates: completion: bash: add correct suffix in variables completion: bash: fix for multiple dash commands completion: bash: fix for suboptions with value completion: bash: fix prefix detection in branch.*
Diffstat (limited to 't')
-rwxr-xr-xt/t9902-completion.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/t/t9902-completion.sh b/t/t9902-completion.sh
index 11573936d5..5decc3b269 100755
--- a/t/t9902-completion.sh
+++ b/t/t9902-completion.sh
@@ -540,6 +540,15 @@ test_expect_success '__gitcomp - expand/narrow all negative options' '
EOF
'
+test_expect_success '__gitcomp - equal skip' '
+ test_gitcomp "--option=" "--option=" <<-\EOF &&
+
+ EOF
+ test_gitcomp "option=" "option=" <<-\EOF
+
+ EOF
+'
+
test_expect_success '__gitcomp - doesnt fail because of invalid variable name' '
__gitcomp "$invalid_variable_name"
'
@@ -2380,6 +2389,12 @@ test_expect_success 'git clone --config= - value' '
EOF
'
+test_expect_success 'options with value' '
+ test_completion "git merge -X diff-algorithm=" <<-\EOF
+
+ EOF
+'
+
test_expect_success 'sourcing the completion script clears cached commands' '
__git_compute_all_commands &&
verbose test -n "$__git_all_commands" &&