aboutsummaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAge
...
* fix(tests): use pending_c_parser when neededbfredl2022-08-25
|
* feat(treesitter): upstream node_length() as a node methodQuentin Rasmont2022-08-25
| | | | Util from the nvim-treesitter project.
* feat(treesitter): upstream get_root_for_node() as a node methodQuentin Rasmont2022-08-25
| | | | Util from the nvim-treesitter project.
* feat(treesitter): upstream get_named_children() as a node methodQuentin Rasmont2022-08-25
| | | | Util from the nvim-treesitter project.
* feat(treesitter): add ability to retreive a tree/node given a rangeQuentin Rasmont2022-08-25
|
* feat(treesitter): upstream is_parent()Quentin Rasmont2022-08-25
| | | | | Util from the nvim-treesitter project. Renamed is_parent to is_ancestor for clarity.
* vim-patch:8.2.0911: crash when opening a buffer for the cmdline window failszeertzjq2022-08-25
| | | | | | | | | | Problem: Crash when opening a buffer for the cmdline window fails. (Chris Barber) Solution: Check do_ecmd() succeeds. Reset got_int if "q" was used at the more prompt. (closes vim/vim#6211) https://github.com/vim/vim/commit/9b7cce28d568f0622d77c6c9878c2d4770c3b164 Make code match latest Vim instead.
* fix(usercmd): also check for whitespace after escaped character (#19942)zeertzjq2022-08-25
|
* test(treesitter): make internal lang test pending when necessaryThomas Vigouroux2022-08-24
|
* feat(lua): add vim.iconv (#18286)Lewis Russell2022-08-24
| | | Co-authored-by: Justin M. Keyes <justinkz@gmail.com>
* Merge pull request #19496 from vigoux/ts_internal_langThomas Vigouroux2022-08-24
|\ | | | | feat(treesitter): allow customizing language symbol name
| * feat(treesitter): allow customizing language symbol nameThomas Vigouroux2022-08-22
| |
* | feat(eval)!: make Vim functions return inner window width and height (#19743)zeertzjq2022-08-24
| | | | | | | | | | | | | | | | | | In non-multigrid UI the only change is that the returned height now excludes winbar, and this is compatible with Vim. In multigrid UI this means the return value of these functions now reflect the space available for buffer lines in a window. No change in nvim_win_get_height() and nvim_win_get_width().
* | fix(path): path_is_url returns false for "foo:/" #19797sigmaSd2022-08-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: path_to_url() returns false for single-slash URIs ("foo:/" vs "foo://"). This is not compliant with the URI spec. https://url.spec.whatwg.org/#url-representation LSP in particular allows single-slash URIs. Solution: Relax path_to_url() to accept single-slash URIs. This is not fully compliant (only ":" is required by the spec), but it is hopefully good enough without causing false-positives in typical text files. ref https://url.spec.whatwg.org/#windows-drive-letter ref https://github.com/neovim/neovim/pull/19773 ref https://github.com/neovim/neovim/pull/19773#issuecomment-1214763769
* | fix(cmdline): do not trigger completion at wrong time (#19920)zeertzjq2022-08-24
| | | | | | Cherry-picked from Vim patches 8.2.4339, 9.0.0238.
* | vim-patch:9.0.0206: redraw flags are not named specifically (#19913)zeertzjq2022-08-23
| | | | | | | | | | Problem: Redraw flags are not named specifically. Solution: Prefix "UPD_" to the flags, for UPDate_screen(). https://github.com/vim/vim/commit/a4d158b3c839e96ed98ff87c7b7124ff4518c4ff
* | vim-patch:8.2.4726: cannot use expand() to get the script namezeertzjq2022-08-23
| | | | | | | | | | | | | | | | | | Problem: Cannot use expand() to get the script name. Solution: Support expand('<script>'). (closes vim/vim#10121) https://github.com/vim/vim/commit/6013d0045dec7ca7c0068fbe186c42d754a7368b Use `.sn_name` instead of `->sn_name` as v8.2.0154 hasn't been ported. Cherry-pick builtin.txt expand() doc from latest Vim.
* | test: add test for using :normal to stop Visual mode in cmdwin (#19904)zeertzjq2022-08-23
| |
* | vim-patch:8.2.1046: insufficient tests for src/buffer.c (#19903)zeertzjq2022-08-23
| | | | | | | | | | | | Problem: Insufficient tests for src/buffer.c. Solution: Add more tests. Move comments related tests to a separate file. (Yegappan Lakshmanan, closes vim/vim#6325) https://github.com/vim/vim/commit/b7e2483655d9b68df0c7349918027d800051a28a
* | vim-patch:8.2.0522: several errors are not tested for (#19901)zeertzjq2022-08-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Several errors are not tested for. Solution: Add tests. (Yegappan Lakshmanan, closes vim/vim#5892) https://github.com/vim/vim/commit/ee4e0c1e9a81cb5d96e0060203a9033c2f28588e Omit Test_range() change: reverted in patch 8.2.0615. Cherry-pick Test_z_no_space_before_xxx() from patch 8.2.0195. Cherry-pick Test_reverse_sort_uniq() change from patch 8.2.0183. Make uniq() error behavior consistent with sort(). Cherry-pick Test_set_ttytype() change from patch 8.1.1826. Cherry-pick quickfix checks from patch 8.1.2373 to test_preview.vim. Test_viminfo_error() is applicable. Cherry-pick E1058 from patch 8.2.0149 and port Test_deep_nest() to Lua.
* | vim-patch:8.1.0832: confirm() is not tested (#19896)zeertzjq2022-08-23
|/ | | | | Problem: confirm() is not tested. Solution: Add a test. (Dominique Pelle, closes vim/vim#3868) https://github.com/vim/vim/commit/2e0500921891e4fec57e97d3c0021aa2d2b4d7ae
* fix(api): avoid side effects with nvim_parse_cmd (#19890)zeertzjq2022-08-22
| | | | Save and restore the cursor and last search pattern and do not change search history.
* fix(edit.c): indentkeys double indent after "!" #12894Axel Forsman2022-08-21
| | | | | | | | | | | | | which is both unexpected and different from the Vim behaviour. Indent was triggered once by the '!' check in insert_execute(), and inserting the char was correctly skipped, but then triggered again in insert_check() (provided that cindent was not being ignored after manual indentation, i.e. `can_cindent == true`). While this is the smallest fix, another solution would be to remove VimState#check and instead move that to *_enter()/-_execute(), since the control flow is pretty unnecessarily convoluted as is. That would also have the benefit of differing less from the Vim source code.
* vim-patch:8.2.4334: command line popup menu not positioned correctlyzeertzjq2022-08-22
| | | | | | | Problem: Command line popup menu not positioned correctly. Solution: Also use vim_strsize() on the existing text. (Naruhiko Nishino, closes vim/vim#9727) https://github.com/vim/vim/commit/68cc2b8a37197872e737fb61244069e13b7227a2
* vim-patch:8.2.4328: command line complete matches cleard when typing characterzeertzjq2022-08-22
| | | | | | | Problem: Command line complete matches cleard when typing character. (Dominique Pellé) Solution: Only remove a popup menu if there is one. https://github.com/vim/vim/commit/73a16c22a4703cb9a7becdf459ce62bd894980d7
* vim-patch:8.2.4325: 'wildmenu' only shows few matches (#19876)zeertzjq2022-08-21
| | | | | | | | | | Problem: 'wildmenu' only shows few matches. Solution: Add the "pum" option: use a popup menu to show the matches. (Yegappan Lakshmanan et al., closes vim/vim#9707) https://github.com/vim/vim/commit/3908ef5017a6b4425727013588f72cc7343199b9 Omit p_wmnu check in cmdline_pum_active() as it can cause problems. Omit vim_strchr() flags as that isn't really better than bitmasks. Omit key translations and document it in vim_diff.txt.
* fix(api/command): fargs behavior when no arguments are passed (#19862)Javier Lopez2022-08-21
| | | | | | | Problem: A command defined with `nargs="?"` returns `fargs={""}` to a Lua callback when executed with no arguments, which is inconsistent with how`nargs="*"` behaves. Solution: Pass `fargs={}` for no argument with `nargs="?"` as well.
* vim-patch:8.1.2045: the option.c file is too big (#19854)zeertzjq2022-08-20
| | | | | | | | | | | Problem: The option.c file is too big. Solution: Split off the code dealing with strings. (Yegappan Lakshmanan, closes vim/vim#4937) https://github.com/vim/vim/commit/dac1347b4d9c1a1aef6aa73fdea08a9d1077d6ea Cherry-pick set_string_option_direct_in_win() from patch 8.1.1405. Cherry-pick shift_line() comment change from patch 8.1.2096. Move 'clipboard' default parsing to didset_string_options(). Reorder option flags to put Nvim-only flags at the end.
* fix(eval): check for v:lua when calling callback (#19855)zeertzjq2022-08-20
| | | This makes callback_call() match call_vim_function() when calling a function.
* refactor: move statusline code from buffer.c and [draw]screen.c to new filebfredl2022-08-19
| | | | | | | | | problem: code for drawing statusline is arbitrarily spreadout between drawscreen.c, screen.c and buffer.c solution: move it to a new file statusline.c - rename archaic internal name "status match" to public name "wildmenu" - showruler() does not show the ruler. it show anything which displays info about the cursor. Rename it accordingy.
* Merge pull request #19360 from famiu/feat/multibuffer-inccommandbfredl2022-08-19
|\ | | | | feat: multibuffer preview support for inccommand
| * feat: multibuffer preview support for inccommandFamiu Haque2022-08-19
| | | | | | | | | | | | | | | | | | Allows preview callbacks to modify multiple buffers in order to show the preview. Previously, if multiple buffers were modified, only the current buffer would have its state restored. After this change, all buffers have their state restored after preview. Closes #19103.
* | vim-patch:8.2.0982: insufficient testing for reading/writing fileszeertzjq2022-08-19
| | | | | | | | | | | | | | | | | | | | Problem: Insufficient testing for reading/writing files. Solution: Add more tests. (Yegappan Lakshmanan, closes vim/vim#6257) Add "ui_delay" to test_override() and use it for the CTRL-O test. https://github.com/vim/vim/commit/b340baed9f7fc1c19a0742e2214d54982190c15e Omit test_override(). Reorder test_writefile.vim to match Vim.
* | vim-patch:8.1.1966: some code in options.c fits better elsewhere (#19840)zeertzjq2022-08-19
| | | | | | | | | | | | Problem: Some code in options.c fits better elsewhere. Solution: Move functions from options.c to other files. (Yegappan Lakshmanan, closes vim/vim#4889) https://github.com/vim/vim/commit/e677df8d93772a705f40a94f3c871aee78fe4d99
* | revert: "jobstart(): Fix hang on non-executable cwd #9204" (#19826)zeertzjq2022-08-18
| | | | | | | | | | This reverts commit c4c74c3883aa3122c0c877ca8dd7b26beb5cc4aa. LibUV already gives an error for this, so this isn't needed.
* | Merge pull request #19822 from bfredl/hldefbfredl2022-08-18
|\ \ | | | | | | fix(api): make nvim_set_hl(ns=0, ...) redraw screen properly
| * | fix(api): make nvim_set_hl(ns=0, ...) redraw screen properlybfredl2022-08-18
| | | | | | | | | | | | fixes #18160
* | | fix(winhl): do not crash when unsetting winhl in just opened windowbfredl2022-08-18
|/ / | | | | | | fixes #19823
* | fix(tests): remove irrelevant usage of display-=msgsepbfredl2022-08-17
| | | | | | | | | | | | | | | | These were just added to avoid churn when changing the default of 'display'. To simplify message handling logic, we might want to remove support for printing messages in default_grid later on. This would allow things like printing error messages safely in the middle of redraw, or a future graduation of the 'multigrid' feature.
* | feat(ui): allow to set the highlight namespace per windowbfredl2022-08-17
| | | | | | | | | | - reimplement 'winhl' in terms of highlight namespaces - check for EOF in screen tests (to indicate a likely crash)
* | feat: allow :wincmd to accept a count (#19815)Famiu Haque2022-08-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Let :wincmd command accept a count like what its documentation suggests. Previously it could only accept a range, which led to some ambiguity on which attribute should be used when executing :wincmd using nvim_cmd. Closes #19662. Also fix a typo in a related Vim test: vim-patch:9.0.0223: typo in diffmode test Problem: Typo in diffmode test. Solution: Fix the typo. (closes vim/vim#10932) https://github.com/vim/vim/commit/5fd6ab820b4a0aaa5c6020852f39d118375fab49
* | vim-patch:9.0.0190: the way 'cmdheight' can be made zero is inconsistentShougo Matsushita2022-08-17
| | | | | | | | | | | | | | Problem: The way 'cmdheight' can be made zero is inconsistent. Solution: Only make 'cmdheight' zero when setting it explicitly, not when resizing windows. (closes vim/vim#10890) https://github.com/vim/vim/commit/f797e309caff48f7a56c73b16e62ff67c4dcbdd6
* | fix(api): nvim_exec and nvim_cmd restore msg_col when capturing output (#19789)zeertzjq2022-08-16
| | | | | | | | This matches the code in execute_common(), preventing messages after the API call from being printed at the wrong column.
* | test: use poke_eventloop() instead of sleep(10) where possible (#19794)zeertzjq2022-08-16
| | | | | | | | Using sleep(10) to wait for typeahead to finish is flaky, especially on macOS, where legacy/global_spec.lua has failed several times.
* | fix(source): fix expand('<sfile>') no longer works for Luazeertzjq2022-08-16
| |
* | vim-patch:8.2.1799: some Normal mode commands not fully testedzeertzjq2022-08-15
| | | | | | | | | | | | | | | | Problem: Some Normal mode commands not fully tested. Solution: Add a few more tests. (Yegappan Lakshmanan, closes vim/vim#7073) https://github.com/vim/vim/commit/d1ad99b65470d3e754f6a0588a6b0dc2214a1eab Cherry-pick test_registers.vim change from patch 8.2.0644.
* | vim-patch:8.2.5109: mode not updated after CTRL-O CTRL-C in Insert modezeertzjq2022-08-15
| | | | | | | | | | | | Problem: Mode not updated after CTRL-O CTRL-C in Insert mode. Solution: Set redraw_mode and use it. (closes vim/vim#10581) https://github.com/vim/vim/commit/7a1d32809bb5c1527314000983e75125d79192e0
* | vim-patch:8.1.1192: mode is not cleared when leaving Insert mode with mapped Esczeertzjq2022-08-15
| | | | | | | | | | | | Problem: Mode is not cleared when leaving Insert mode with mapped Esc. Solution: Clear the mode when redraw_cmdline is set. (closes vim/vim#4269) https://github.com/vim/vim/commit/4c25bd785aa8b565bf973cbba12ed36b76daaa4f
* | vim-patch:8.1.1189: mode is not cleared when leaving Insert modezeertzjq2022-08-15
| | | | | | | | | | | | Problem: Mode is not cleared when leaving Insert mode. Solution: Clear the mode when got_int is set. (Ozaki Kiichi, closes vim/vim#4270) https://github.com/vim/vim/commit/abc7c7fc5a098374f5543a237e6c9dd918848b34
* | fix(getchar): flush screen before doing a blocking waitzeertzjq2022-08-15
| |