aboutsummaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAge
...
* | fix(column): crash with 'signcolumn' set to "number" (#29003)luukvbaal2024-06-01
| | | | | | | | | | | | Problem: Numberwidth may depend on number of signs with text in the buffer and is not handled correctly for extmark signs. Solution: Move legacy sign code for changed numberwidth so that it is handled properly for legacy and extmark signs alike.
* | docs(luacats): add tuple supportIlia Choly2024-05-31
| |
* | vim-patch:9.1.0454: minor issues in test_filetype with rasi testChristian Clason2024-05-31
| | | | | | | | | | | | | | | | | | | | Problem: minor issues in test_filetype with rasi test (after 9.1.0453) Solution: re-sort test_filetype, fix wrong syntax.txt help tags https://github.com/vim/vim/commit/f3dd6f617c65a9b939697362efe6833eb2778612 Co-authored-by: Christian Brabandt <cb@256bit.org>
* | vim-patch:9.1.0453: filetype: rasi files are not recognizedChristian Clason2024-05-31
|/ | | | | | | | | | | | | | | Problem: filetype: rasi files are not recognized Solution: regonize '*.rasi' files as rasi filetype, include a filetype and syntax plugin (Pierrick Guillaume) ported from: https://github.com/Fymyte/rasi.vim closes: vim/vim#14821 https://github.com/vim/vim/commit/280e5b13ca568ed592a894140bf1ac74356f4b33 Co-authored-by: Pierrick Guillaume <pierguill@gmail.com>
* vim-patch:9.1.0451: No test for escaping '<' with shellescape()zeertzjq2024-05-31
| | | | | | | | | | Problem: No test for escaping '<' with shellescape() Solution: Add a test. Use memcpy() in code to make it easier to understand. Fix a typo (zeertzjq). closes: vim/vim#14876 https://github.com/vim/vim/commit/88c8c547d5fc380e5685c2b01ec564ccdf9b259a
* refactor(lsp): replace util.buf_versions with changedtick (#28943)Mathias Fußenegger2024-05-30
| | | | | | | `lsp.util.buf_versions` was already derived from changedtick (`on_lines` from `buf_attach` synced the version) As far as I can tell there is no need to keep track of the state in a separate table.
* feat(lsp): support postfix snippets in completionMathias Fussenegger2024-05-30
|
* feat(lsp): use fuzzy match on filterText instead of prefix matchMathias Fussenegger2024-05-30
| | | | | | | | The `complete()` mechanism matches completion candidates against the typed text, so strict pre-filtering isn't necessary. This is a first step towards supporting postfix snippets (like `items@insert` in luals)
* vim-patch:8.2.3061: testing the shell option is incomplete and spread out ↵zeertzjq2024-05-30
| | | | | | | | | | | (#29090) Problem: Testing the shell option is incomplete and spread out. Solution: Move shell tests to one file and increase coverage. (Yegappan Lakshmanan, closes vim/vim#8464) https://github.com/vim/vim/commit/054794c20f6322bbd9482c4124041dc0a140c78e Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
* Merge pull request #29016 from bfredl/shadareaderbfredl2024-05-29
|\ | | | | refactor(shada): remove ShaDaReadDef secondary wrapper
| * refactor(shada): remove ShaDaReadDef secondary wrapperbfredl2024-05-28
| | | | | | | | | | | | `FileDescriptor` is already a wrapper around an fd and a buffer. By allowing to just use the buffer without an fd, it can already handle in-memory reads.
* | build: reuse code for deps.txt for both deps and main builddundargoc2024-05-28
| |
* | feat(defaults): use vim.diagnostic.jump() for default mappings (#29066)Gregory Anders2024-05-28
| | | | | | | | This allows the mappings to work with a count and also enables new ]D and [D mappings to go to the last/first diagnostic in the buffer.
* | Merge pull request #27339 from MariaSolOs/completionGregory Anders2024-05-28
|\ \ | | | | | | feat(lsp): completion side effects
| * | feat(snippet): add default keymaps during snippet sessionMaria José Solano2024-05-28
| | |
| * | test(lsp): add completion testsMaria José Solano2024-05-27
| | |
| * | feat(lsp): completion side effectsMaria José Solano2024-05-27
| | |
* | | feat(diagnostic): add vim.diagnostic.jump() (#26745)Gregory Anders2024-05-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Deprecate vim.diagnostic.goto_prev() and vim.diagnostic.goto_next() in favor of a unified vim.diagnostic.jump() interface. We cannot name the function "goto()" because some of our tooling (luacheck and stylua) fail to parse it, presumably because "goto" is a keyword in newer versions of Lua. vim.diagnostic.jump() also allows moving to a specific diagnostic and moving by multiple diagnostics at a time (useful for creating mappings that use v:count).
* | | fix(ui): flush ext_cmdline events before doing cmdpreview #27950luukvbaal2024-05-28
| |/ |/| | | | | Problem: Unable to update the screen for external cmdline during cmdpreview. Solution: Flush the cmdline UI before cmdpreview state.
* | fix(runtime): source c ftplugin properly for cpp on Windows (#29053)zeertzjq2024-05-28
| | | | | | | | | | | | | | | | On Windows, '{' is currently not treated as a wildcard char, so another wildcard char is needed for the pattern to be treated as a wildcard. It may be worth trying to make '{' always a wildcard char in the future, but that'll be a bit harder as it'll be necessary to make sure '{' is escaped at various places.
* | fix(lsp): do not detach from buffer if there are uninitialized clients (#29029)Ilia Choly2024-05-27
| | | | | | | | | | Problem: if on_lines is called before the LSP is initialized, the buffer is detached. Solution: check for uninitialized clients before detaching.
* | vim-patch:9.1.0447: completion may be wrong when deleting all chars (#29040)glepnir2024-05-27
| | | | | | | | | | | | | | | | Problem: completion may be wrong when deleting all chars. Solution: reset compl_shown_match (glepnir). closes: https://github.com/vim/vim/pull/14854 https://github.com/vim/vim/commit/53387c55a13bc1013a6ab721d4bd0bd04c6935c4
* | perf: add fast path to vim.validate (#28977)Gregory Anders2024-05-27
| | | | | | | | | | | | For many small/simple functions (like those found in shared.lua), the runtime of vim.validate can far exceed the runtime of the function itself. Add an "overload" to vim.validate that uses a simple assertion pattern, rather than parsing a full "validation spec".
* | fix(treesitter): find buffer in multiple windows #28922Guilherme Soares2024-05-27
| | | | | | | | | | | | | | | | | | | | | | | | | | Problem: 1. When interacting with multiple :InspectTree and the source buffer windows there is a high chance of errors due to the window ids not being updated and validated. 2. Not all InspectTree windows were closed when the source buffer was closed. Solution: 1. Update InspectTree window id on `CursorMoved` event and validate source buffer window id before trying to navigate to it. 2. Close all InspectTree windows
* | fix(drawline): don't draw beyond end of window (#29035)zeertzjq2024-05-27
| |
* | vim-patch:9.1.0446: getregionpos() inconsistent for partly-selected ↵zeertzjq2024-05-27
| | | | | | | | | | | | | | | | | | | | | | | | multibyte char (#29032) Problem: getregionpos() behaves inconsistently for a partly-selected multibyte char. Solution: Always use column of the first byte for a partly-selected multibyte char (zeertzjq). closes: vim/vim#14851 https://github.com/vim/vim/commit/ef73374dc3e4bf8104ba31d5b22517f8028b467a
* | fix(tui): reset clear_region attributes during startup #28713luukvbaal2024-05-26
| | | | | | | | | | | | Problem: Fix added in #28676 worked accidentally(used variables were themselves uninitialized at this point during startup) and does not always work. Solution: Reset attributes when clearing regions during startup.
* | fix(tohtml): properly handle multiple hl groups #29012Riley Bruins2024-05-26
| | | | | | | | | | | | | | | | | | Problem: :TOhtml doesn't properly handle virtual text when it has multiple highlight groups. It also improperly calculates position offset for multi-byte virt_text characters. Solution: Apply the `vim.api.nvim_strwidth` broadly to properly calculate character offset, and handle the cases where the `hl` argument can be a table of multiple hl groups.
* | refactor(tests): more global highlight definitionsbfredl2024-05-26
| |
* | Merge pull request #29006 from bfredl/apitestbfredl2024-05-26
|\ \ | | | | | | refactor(tests): use more global highlight definitions
| * | refactor(tests): use more global highlight definitionsbfredl2024-05-26
| | |
* | | vim-patch:9.1.0442: hare runtime files outdated (#29011)zeertzjq2024-05-26
|/ / | | | | | | | | | | | | | | | | | | | | Problem: hare runtime files outdated Solution: runtime(hare): update hare.vim to match upstream (Amelia Clarke) closes: vim/vim#14836 https://github.com/vim/vim/commit/35dfe58a540e2fb0eff953630f8e4fcbf4bc26ca Co-authored-by: Amelia Clarke <selene@perilune.dev>
* | refactor(tests): update screen:snapshot_util() to use new-style highlightsbfredl2024-05-25
| | | | | | | | | | | | | | | | | | | | | | This makes screen:snapshot_util() generate code with the new screen:add_extra_attr_ids { ... } pattern. For convenience, the old-style configuration is still detected and supported (until all tests have been refactored, which is my goal for the 0.11 cycle) Remove the last traces of the "ignore" attr anti-pattern. This code is no longer functional, it is just "ignore" argument being passed around like a hot potato at this point.
* | test(unit): skip flaky 'typval.c dict extend() works' testdundargoc2024-05-25
| |
* | refactor(lua): rewrite vim.highlight.range() (#28986)zeertzjq2024-05-25
| | | | | | | | - Use getregionpos(). - Use a single extmark for non-blockwise selection.
* | Merge pull request #28617 from glepnir/border_hlbfredl2024-05-25
|\ \ | | | | | | fix(float): missing default highlight for title
| * | fix(float): missing default highlight for titleglepnir2024-05-25
| | | | | | | | | | | | | | | | | | Problem: there is missing default title highlight when highlight not defined in title text chunk. Solution: when attr is not set use default title highlight group.
* | | vim-patch:9.1.0444: Not enough tests for getregion() with multibyte chars ↵zeertzjq2024-05-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#29000) Problem: Not enough tests for getregion() with multibyte chars. Solution: Add a few more tests (zeertzjq). closes: vim/vim#14844 https://github.com/vim/vim/commit/dff55a335889c746a79974f7c52cdcdebad682c2
* | | vim-patch:9.1.0443: Can't use blockwise selection with width for getregion() ↵zeertzjq2024-05-25
| |/ |/| | | | | | | | | | | | | | | | | | | | | (#28985) Problem: Can't use a blockwise selection with a width for getregion(). Solution: Add support for blockwise selection with width like the return value of getregtype() or the "regtype" value of TextYankPost (zeertzjq). closes: vim/vim#14842 https://github.com/vim/vim/commit/afc2295c2201ae87bfbb42d5f5315ad0583ccabf
* | fix(fs): make vim.fs.root work for relative paths and unnamed buffers (#28964)Gregory Anders2024-05-24
| | | | | | | | If a buffer does not have a backing file then fall back to the current working directory.
* | vim-patch:8.2.3158: strange error message when using islocked() with a ↵zeertzjq2024-05-24
| | | | | | | | | | | | | | | | | | | | | | | | | | number (#28962) Problem: Strange error message when using islocked() with a number. (Yegappan Lakshmanan) Solution: Check that the name is empty. https://github.com/vim/vim/commit/1840a7b4e3577e617f724c9d07ccc78195cc010a Use ll_name_len instead. Co-authored-by: Bram Moolenaar <Bram@vim.org>
* | feat(complete): specify reason for CompleteDoneFamiu Haque2024-05-24
| | | | | | | | | | Problem: `CompleteDone` currently does not specify the reason for why completion was done, which is problematic for completion plugins as they cannot know whether the event was triggered due to the completion being canceled, accepted, or for some other reason. Solution: Add a `reason` key to `v:event`, which is set by `CompleteDone` to indicate why completion ended.
* | fix: change deprecation presentationdundargoc2024-05-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Deprecation with vim.deprecate is currently too noisy. Show the following warning instead: [function] is deprecated. Run ":checkhealth vim.deprecated" for more information. The important part is that the full message needs to be short enough to fit in one line in order to not trigger the "Press ENTER or type command to continue" prompt. The full information and stack trace for the deprecated functions will be shown in the new healthcheck `vim.deprecated`.
* | vim-patch:9.1.0439: Cannot filter the history (#28958)zeertzjq2024-05-24
| | | | | | | | | | | | | | | | | | | | Problem: Cannot filter the history Solution: Implement :filter :history closes: vim/vim#14835 https://github.com/vim/vim/commit/42a5b5a6d0d05255b9c464abe71f29c7677b5833 Co-authored-by: Christian Brabandt <cb@256bit.org>
* | vim-patch:9.1.0441: getregionpos() can't properly indicate positions beyond ↵zeertzjq2024-05-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | eol (#28957) Problem: getregionpos() can't properly indicate positions beyond eol. Solution: Add an "eol" flag that enables handling positions beyond end of line like getpos() does (zeertzjq). Also fix the problem that a position still has the coladd beyond the end of the line when its column has been clamped. In the last test case with TABs at the end of the line the old behavior is obviously wrong. I decided to gate this behind a flag because returning positions that don't correspond to actual characters in the line may lead to mistakes for callers that want to calculate the length of the selected text, so the behavior is only enabled if the caller wants it. closes: vim/vim#14838 https://github.com/vim/vim/commit/2b09de910458247b70751928217422c38fd5abf8
* | vim-patch:9.1.0438: Wrong Ex command executed when :g uses '?' as delimiter ↵zeertzjq2024-05-24
| | | | | | | | | | | | | | | | | | | | | | (#28956) Problem: Wrong Ex command executed when :g uses '?' as delimiter and pattern contains escaped '?'. Solution: Don't use "*newp" when it's not allocated (zeertzjq). closes: vim/vim#14837 https://github.com/vim/vim/commit/3074137542961ce7b3b65c14ebde75f13f5e6147
* | vim-patch:9.1.0436: Crash when using '?' as separator for :s (#28955)zeertzjq2024-05-24
| | | | | | | | | | | | | | | | | | | | Problem: Crash when using '?' as separator for :s and pattern contains escaped '?'s (after 9.1.0409). Solution: Always compute startplen. (zeertzjq). related: neovim/neovim#28935 closes: 14832 https://github.com/vim/vim/commit/789679cfc4f39505b135220672b43a260d8ca3b4
* | vim-patch:9.1.0435: filetype: cygport files are not recognizedChristian Clason2024-05-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: filetype: cygport files are not recognized Solution: Recognize '*.cygport' files as sh filetype (Ken Takata) https://cygwin.github.io/cygport/cygport_in.html closes: vim/vim#14833 https://github.com/vim/vim/commit/cd79f8fbd34cdb918153d9fa3821eb4092b7b5fc Co-authored-by: K.Takata <kentkt@csc.jp>
* | fix(comment): fall back to using trimmed comment markers (#28938)Evgeni Chasnovski2024-05-23
| | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Currently comment detection, addition, and removal are done by matching 'commentstring' exactly. This has the downside when users want to add comment markers with space (like with `-- %s` commentstring) but also be able to uncomment lines that do not contain space (like `--aaa`). Solution: Use the following approach: - Line is commented if it matches 'commentstring' with trimmed parts. - Adding comment is 100% relying on 'commentstring' parts (as is now). - Removing comment is first trying exact 'commentstring' parts with fallback on trying its trimmed parts.
* | fix(lsp): check if buffer was detached in on_init callback (#28914)Ilia Choly2024-05-23
| | | | | | Co-authored-by: Jongwook Choi <wookayin@gmail.com>