aboutsummaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAge
...
* fix(pum): don't select item when clicking to the left/right (#30967)zeertzjq2024-10-28
| | | | | | | Problem: Selecting an item in the right-click menu when clicking to the left/right of it is confusing, especially in a UI that doesn't support 'mousemoveevent'. Solution: Don't select an item when clicking to the left/right of the right-click menu.
* feat(diagnostics)!: sort underline severity_sort (#30898)Donatas2024-10-27
| | | | | feat(diagnostics)!: sort underline with severity_sort BREAKING CHANGE: underline will be applied with a higher value than `vim.hl.priorities.diagnostics`
* refactor(lsp): drop str_byteindex/str_utfindex wrappers #30915Tristan Knight2024-10-26
| | | | | * deprecate old signatures * move to new str_byteindex/str_utfindex signature * use single-underscore name (double-underscore is reserved for Lua itself)
* refactor(options)!: use OptVal for option defaults #26691Famiu Haque2024-10-25
| | | | | | | | | Problem: We use `void *` for option default values, which is confusing and can cause problems with type-correctness. It also doesn't accomodate for multitype options. On top of that, it also leads to default boolean option values not behaving correctly on big endian systems. Solution: Use `OptVal` for option default values. BREAKING CHANGE: - `:set {option}<` removes the local value for all global-local options instead of just string global-local options. - `:setlocal {option}<` copies the global value to the local value for number and boolean global-local options instead of removing the local value.
* vim-patch:9.1.0814: mapset() may remove unrelated mapping (#30941)zeertzjq2024-10-24
| | | | | | | | | Problem: mapset() may remove unrelated mapping whose {rhs} matches the restored mapping's {lhs}. Solution: only match by {lhs} when unmapping for mapset() (zeertzjq). closes: vim/vim#15935 https://github.com/vim/vim/commit/fdf135a0525746cc0ff85bed2fbbde320ddb6d0d
* fix(lsp): set tagstack on jump via goto methodsMathias Fussenegger2024-10-24
| | | | | Follow up to https://github.com/neovim/neovim/pull/30877 Fixes https://github.com/neovim/neovim/issues/30926
* fix(options): missing error check for global 'scl' and 'winhl' (#30919)zeertzjq2024-10-24
|
* test(012_directory_spec): fix flakiness on Windows (#30920)zeertzjq2024-10-24
| | | | Problem: 012_directory_spec is flaky on Windows. Solution: Use :%bwipe! instead :qall!.
* test(old): remove unnecessary :setglobal skipszeertzjq2024-10-24
|
* vim-patch:9.1.0806: tests: no error check when setting global 'briopt'zeertzjq2024-10-24
| | | | | | | | | | | Problem: tests: no error check when setting global 'briopt' Solution: also parse and check global 'briopt' value (Milly) closes: vim/vim#15911 https://github.com/vim/vim/commit/b38700ac81d90a652e5c8495056dd78df5babdde Co-authored-by: Milly <milly.ca@gmail.com>
* vim-patch:9.1.0804: tests: no error check when setting global 'cc'zeertzjq2024-10-24
| | | | | | | | | | | Problem: tests: no error check when setting global 'cc' Solution: also parse and check global 'cc' value (Milly) closes: vim/vim#15914 https://github.com/vim/vim/commit/a441a3eaabbfc14b4772e07ecbecaaff3bd06a58 Co-authored-by: Milly <milly.ca@gmail.com>
* vim-patch:9.1.0803: tests: no error check when setting global 'isk'zeertzjq2024-10-24
| | | | | | | | | | | Problem: tests: no error check when setting global 'isk' Solution: also parse and check global 'isk' value (Milly) closes: vim/vim#15915 https://github.com/vim/vim/commit/5e7a6a4a106923e45c67dae6810e4c9753f88025 Co-authored-by: Milly <milly.ca@gmail.com>
* vim-patch:9.1.0802: tests: no error check when setting global 'fdm' to empty ↵zeertzjq2024-10-24
| | | | | | | | | | | | | value Problem: tests: no error check when setting global 'fdm' to empty value Solution: Also check global 'fdm' value for being empty (Milly). closes: vim/vim#15916 https://github.com/vim/vim/commit/142cad1f88d1d3aa34b6050151e620b66185112e Co-authored-by: Milly <milly.ca@gmail.com>
* feat(stdlib): overload vim.str_byteindex, vim.str_utfindex #30735Tristan Knight2024-10-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PROBLEM: There are several limitations to vim.str_byteindex, vim.str_utfindex: 1. They throw given out-of-range indexes. An invalid (often user/lsp-provided) index doesn't feel exceptional and should be handled by the caller. `:help dev-error-patterns` suggests that `retval, errmsg` is the preferred way to handle this kind of failure. 2. They cannot accept an encoding. So LSP needs wrapper functions. #25272 3. The current signatures are not extensible. * Calling: The function currently uses a fairly opaque boolean value to indicate to identify the encoding. * Returns: The fact it can throw requires wrapping in pcall. 4. The current name doesn't follow suggestions in `:h dev-naming` and I think `get` would be suitable. SOLUTION: - Because these are performance-sensitive, don't introduce `opts`. - Introduce an "overload" that accepts `encoding:string` and `strict_indexing:bool` params. ```lua local col = vim.str_utfindex(line, encoding, [index, [no_out_of_range]]) ``` Support the old versions by dispatching on the type of argument 2, and deprecate that form. ```lua vim.str_utfindex(line) -- (utf-32 length, utf-16 length), deprecated vim.str_utfindex(line, index) -- (utf-32 index, utf-16 index), deprecated vim.str_utfindex(line, 'utf-16') -- utf-16 length vim.str_utfindex(line, 'utf-16', index) -- utf-16 index vim.str_utfindex(line, 'utf-16', math.huge) -- error: index out of range vim.str_utfindex(line, 'utf-16', math.huge, false) -- utf-16 length ```
* vim-patch:9.1.0809: filetype: petalinux config files not recognizedChristian Clason2024-10-23
| | | | | | | | | | | | | | | Problem: filetype: petalinux config files not recognized Solution: detect 'project-spec/*.conf' files as bitbake filetype (Wu, Zhenyu) References: https://www.amd.com/en/products/software/adaptive-socs-and-fpgas/embedded-software/petalinux-sdk.html closes: vim/vim#15926 https://github.com/vim/vim/commit/626b6ab48682b211c22ede5a6e63513c85f93e58 Co-authored-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
* vim-patch:9.1.0805: tests: minor issues in gen_opt_test.vimzeertzjq2024-10-23
| | | | | | | | | | | | | | | Problem: tests: minor issues in gen_opt_test.vim Solution: fix restore value for 'undolevels', fix comment, fix wrong cpo value, add equality test for global-local options on switchback (Milly). closes: vim/vim#15913 https://github.com/vim/vim/commit/231480f9753fa3fb28e17b670550ce43172c0eba Cherry-pick gen_opt_test.vim change from patch 9.1.0807. Co-authored-by: Milly <milly.ca@gmail.com>
* vim-patch:9.1.0799: tests: gettwinvar()/gettabwinvar() tests are not ↵zeertzjq2024-10-23
| | | | | | | | | | | | | comprehensive Problem: tests: gettwinvar()/gettabwinvar() tests are not comprehensive Solution: Add more tests (Milly) closes: vim/vim#15920 https://github.com/vim/vim/commit/ceec8640df0f75c6e7759fbb3d7a1064313321fb Co-authored-by: Milly <milly.ca@gmail.com>
* test: port libvterm unit test to neovim test suitedundargoc2024-10-22
| | | | | | | These were imported from the v0.3.3 git tag https://github.com/neovim/libvterm/tree/v0.3.3 and not the latest commit. This is for compatibility reasons as the libvterm code was imported from v0.3.3.
* fix(options): fix 'winhl' still accepting invalid value (#30896)zeertzjq2024-10-22
|
* vim-patch:9.1.0796: filetype: libtool files are not recognizedChristian Clason2024-10-22
| | | | | | | | | | | | Problem: filetype: libtool files are not recognized Solution: detect '*.{lo,la,lai}' as sh filetype (Wu, Zhenyu) closes: vim/vim#15751 https://github.com/vim/vim/commit/bfe568d8c49662c3a3485834066c0a4c32ded56b Co-authored-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
* vim-patch:9.1.0795: filetype: Vivado memory info file are not recognizedChristian Clason2024-10-22
| | | | | | | | | | | | | | Problem: filetype: Vivado memory info file are not recognized Solution: detect '*.mmi' memory info file as xml filetype (Wu, Zhenyu) References: https://docs.amd.com/r/en-US/ug1580-updatemem/MMI-File-Syntax closes: vim/vim#15906 https://github.com/vim/vim/commit/0887e62bce3f46c20d2fa5f8ece1ca001e44ce63 Co-authored-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
* fix(options): fix :setglobal not working for 'spelloptions' (#30894)zeertzjq2024-10-22
|
* vim-patch:9.1.0797: testing of options can be further improved (#30893)zeertzjq2024-10-22
| | | | | | | | | | | Problem: testing of options can be further improved Solution: split the generated option test into test_options_all.vim, add more test cases, save and restore values, fix use-after-free closes: vim/vim#15894 https://github.com/vim/vim/commit/6eca04e9f1d446dc509ba51e32da56fa413fe2f0 Co-authored-by: Milly <milly.ca@gmail.com>
* feat(vim.validate): improve fast form and deprecate spec formLewis Russell2024-10-21
| | | | | | | | | | | | | | Problem: `vim.validate()` takes two forms when it only needs one. Solution: - Teach the fast form all the features of the spec form. - Deprecate the spec form. - General optimizations for both forms. - Add a `message` argument which can be used alongside or in place of the `optional` argument.
* test(rpc): retry flaky 'vim.rpcrequest and vim.rpcnotify' testChristian Clason2024-10-21
| | | | | | Problem: 'vim.rpcrequest and vim.rpcnotify' is flaky on Windows. Solution: retry it.
* refactor: rename vim.highlight => vim.hlJustin M. Keyes2024-10-21
| | | | | | | | | | | | Problem: - `vim.highlight` module does not follow `:help dev-name-common`, which documents the name for "highlight" as "hl". - Shorter names are usually preferred. Solution: Rename `vim.highlight` to `vim.hl`. This is not a breaking change until 2.0 (or maybe never).
* fix(lua): vim.deprecate does not support major>0Justin M. Keyes2024-10-21
|
* feat(lsp)!: support multiple clients in goto methods (#30877)Mathias Fußenegger2024-10-20
| | | | | | | | | | | | | | | Relates to: - https://github.com/neovim/neovim/issues/30034 - https://github.com/neovim/neovim/issues/17712 - https://github.com/neovim/neovim/issues/16363 Closes: - https://github.com/neovim/neovim/issues/26936 (but only provides bufnr and method) - https://github.com/neovim/neovim/issues/22318 Might fix: https://github.com/neovim/neovim/issues/30737
* feat(float): allow enabling mouse for non-focusable window (#30844)zeertzjq2024-10-20
| | | | Problem: Cannot allow mouse interaction for non-focusable float window. Solution: Add a "mouse" field to float window config.
* vim-patch:9.1.0794: tests: tests may fail on Windows environment (#30874)zeertzjq2024-10-20
| | | | | | | | | | | | | | Problem: tests: tests may fail on Windows environment Solution: use shellcmdflag=/D to skip executing autorun from the registry (Milly) closes: vim/vim#15900 https://github.com/vim/vim/commit/4f5681dbdfaf25f3357cba3172906c076421c7b9 Cherry-pick Test_cursorhold_insert_with_timer_interrupt() change from patch 8.2.1836. Co-authored-by: Milly <milly.ca@gmail.com>
* vim-patch:9.1.0792: tests: Test_set_values() is not comprehensive enough ↵zeertzjq2024-10-20
| | | | | | | | | | | | (#30870) Problem: tests: Test_set_values() is not comprehensive enough Solution: Add a lot more test cases (Milly) closes: vim/vim#15892 https://github.com/vim/vim/commit/cc15bbcbc471a206e995e147a09a0720b9f35a38 Co-authored-by: Milly <milly.ca@gmail.com>
* feat(terminal)!: make 'belloff' and 'visualbell' apply to terminal bell (#30859)zeertzjq2024-10-20
| | | | | | | vim-patch:8.2.4744: a terminal window can't use the bell vim-patch:8.2.4745: using wrong flag for using bell in the terminal BREAKING CHANGE: Bells from :terminal are now silent by default, unless 'belloff' option doesn't contain "term" or "all".
* fix(options): fix some 'belloff' flags not working properly (#30856)zeertzjq2024-10-18
| | | | Problem: Some 'belloff' flags don't work properly. Solution: Keep BO_ flags and p_bo_values[] in sync.
* vim-patch: make gen_opt_test.vim work with Nvim (#30850)zeertzjq2024-10-18
| | | | | | | Problem: Insufficient test coverage for validation of option values. Solution: Port Vim's gen_opt_test.vim and make it work with Nvim. vim-patch:9.1.0760: tests: no error reported, if gen_opt_test.vim fails vim-patch:9.1.0791: tests: errors in gen_opt_test.vim are not shown
* feat(vim.ui.open): support lemonade #30845Uthman Mohamed2024-10-18
|
* Merge pull request #30825 from lewis6991/refactor/lsputilLewis Russell2024-10-17
|\
| * fix(lsp.util): inconsistent handling of offset_encodingLewis Russell2024-10-17
| |
| * feat(lsp.util): refactor symbols_to_items()Lewis Russell2024-10-17
| | | | | | | | | | - Remove the trivial function vim.lsp.util._get_symbol_kind_name() and its tests.
* | vim-patch:9.1.0789: tests: ':resize + 5' has invalid space after '+' (#30835)zeertzjq2024-10-17
|/ | | | | | | | | | Problem: tests: ':resize + 5' has invalid space after '+' Solution: Correct the test (Milly) closes: vim/vim#15884 https://github.com/vim/vim/commit/c0cba184f54e052cf8f04baca24bdee72a4b7de6 Co-authored-by: Milly <milly.ca@gmail.com>
* vim-patch:9.1.0786: tests: quickfix update test does not test location list ↵zeertzjq2024-10-16
| | | | | | | | | | | | | | (#30828) Problem: tests: quickfix update test does not test location list (after: v9.1.0.785) Solution: update Test_quickfix_buffer_contents to test with location lists (Yegappan Lakshmanan) closes: vim/vim#15879 https://github.com/vim/vim/commit/6a1deaf5adf4dddea0d27a7f18792ae8d870805e Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* vim-patch:9.1.0785: cannot preserve error position when setting quickfix ↵zeertzjq2024-10-15
| | | | | | | | | | | | | | list (#30820) Problem: cannot preserve error position when setting quickfix lists Solution: Add the 'u' action for setqflist()/setloclist() and try to keep the closes target position (Jeremy Fleischman) fixes: vim/vim#15839 closes: vim/vim#15841 https://github.com/vim/vim/commit/27fbf6e5e8bee5c6b61819a5e82a0b50b265f0b0 Co-authored-by: Jeremy Fleischman <jeremyfleischman@gmail.com>
* fix(lsp): handle multiline signature help labels #30460Maria José Solano2024-10-15
|
* vim-patch:9.1.0782: tests: using wrong neomuttlog file nameChristian Clason2024-10-15
| | | | | | | | | | | Problem: tests: using wrong neomuttlog file name Solution: use correct file name related: vim/vim#15858 https://github.com/vim/vim/commit/0c59c3027199ce593f6612d7cd418f375933c7cb Co-authored-by: Christian Brabandt <cb@256bit.org>
* vim-patch:9.1.0783: 'spell' option setting has problems (#30818)zeertzjq2024-10-15
| | | | | | | | | | | Problem: 'spell' option setting has problems Solution: correctly check for comma for 'spellfile' option, remove unnecessary checks, refactor slightly (Milly) closes: vim/vim#15873 https://github.com/vim/vim/commit/322ad0c953b7a3023cd2a65db61d05e180a5d682 Co-authored-by: Milly <milly.ca@gmail.com>
* fix(tui): avoid flushing buffer halfway an OSC 2 sequence (#30793)zeertzjq2024-10-15
| | | | | | Problem: Setting title while TUI buffer is almost full may cause the end of a flush to be treated as a part of an OSC 2 or OSC 0 sequence, leading to problems like invisible cursor. Solution: Make the whole sequence to set title a unibi_ext string.
* vim-patch:9.1.0781: tests: test_filetype failsChristian Clason2024-10-14
| | | | | | | | | | | | Problem: tests: test_filetype fails (clason) (after v9.1.0779) Solution: Use correct filename for neomuttlog filetype related: vim/vim#15845 https://github.com/vim/vim/commit/7d755d8ef328a3eced18c57ea1b569898cc448a2 Co-authored-by: Christian Brabandt <cb@256bit.org>
* vim-patch:9.1.0779: filetype: neomuttlog files are not recognizedChristian Clason2024-10-14
| | | | | | | | | | | | | Problem: filetype: neomuttlog files are not recognized Solution: detect '*.neomuttdebug' file as neomuttlog filetype, include neomuttlog syntax script (Richard Russon) closes: vim/vim#15858 https://github.com/vim/vim/commit/a2aa921f767da17d4b619f41b7a1210c762c91e2 Co-authored-by: Richard Russon <rich@flatcap.org> Co-authored-by: AvidSeeker <avidseeker7@protonmail.com>
* vim-patch:9.1.0778: filetype: lf config files are not recognizedChristian Clason2024-10-14
| | | | | | | | | | | | | | | Problem: filetype: lf config files are not recognized Solution: detect lfrc files as lf filetype, include a syntax script for lf files (Andis Spriņķis). References: - https://github.com/gokcehan/lf closes: vim/vim#15859 https://github.com/vim/vim/commit/0f146b7925178a5bdfdc8e07642976f0b76d9612 Co-authored-by: Andis Spriņķis <spr.andis@protonmail.com>
* test(tui_spec): use Unicode in cursor_address test (#30807)zeertzjq2024-10-14
| | | | | | Now that #16425 is fixed, use Unicode again to reduce screen height. Unfortunately composing chars still can't be used, as it turns out that composing chars may be missing when sent separately from the base char at the last char a screen line.
* vim-patch:a420547: runtime(misc): Use consistent "Vim script" spelling (#30805)zeertzjq2024-10-14
| | | | | | | | | References: https://groups.google.com/g/vim_dev/c/3Z5yM8KER2w/m/wAqws0QSEAAJ closes: vim/vim#15863 https://github.com/vim/vim/commit/a4205471adae39c80fb7f151a4f33051fcb80001 Co-authored-by: h-east <h.east.727@gmail.com>