aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2024-10-07 10:16:47 +0800
committerGitHub <noreply@github.com>2024-10-07 10:16:47 +0800
commit40ec3d7bc0e255a1159f4b2c27c6dcea5d13ca3d (patch)
tree406c111a9d008a112bab556b6d94d16ff6409ed8 /test
parentd0dc2920e11363ead767c438f2785c73853bdc46 (diff)
downloadrneovim-40ec3d7bc0e255a1159f4b2c27c6dcea5d13ca3d.tar.gz
rneovim-40ec3d7bc0e255a1159f4b2c27c6dcea5d13ca3d.tar.bz2
rneovim-40ec3d7bc0e255a1159f4b2c27c6dcea5d13ca3d.zip
vim-patch:9.1.0761: :cd completion fails on Windows with backslash in path (#30703)
Problem: :cd completion fails on Windows with backslash in path Solution: switch no_bslash argument to FALSE in file_pat_to_reg_pat() Note: only fixes the problem on Windows. For Unix, we still need to escape backslashes since those are taken as regex atoms (and could be invalid regex atoms). fixes: vim/vim#15643 closes: vim/vim#15808 https://github.com/vim/vim/commit/1a31c430bb175144d097ca607dbe10d7960f372a Co-authored-by: Christian Brabandt <cb@256bit.org>
Diffstat (limited to 'test')
-rw-r--r--test/old/testdir/test_cmdline.vim11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/old/testdir/test_cmdline.vim b/test/old/testdir/test_cmdline.vim
index d8a217fd05..9f25a42c38 100644
--- a/test/old/testdir/test_cmdline.vim
+++ b/test/old/testdir/test_cmdline.vim
@@ -4070,4 +4070,15 @@ func Test_term_option()
let &cpo = _cpo
endfunc
+func Test_cd_bslsh_completion_windows()
+ CheckMSWindows
+ let save_shellslash = &shellslash
+ set noshellslash
+ call system('mkdir XXXa\_b')
+ defer delete('XXXa', 'rf')
+ call feedkeys(":cd XXXa\\_b\<C-A>\<C-B>\"\<CR>", 'tx')
+ call assert_equal('"cd XXXa\_b\', @:)
+ let &shellslash = save_shellslash
+endfunc
+
" vim: shiftwidth=2 sts=2 expandtab