summaryrefslogtreecommitdiffstatshomepage
path: root/test/functional/editor/put_spec.lua
AgeCommit message (Collapse)AuthorFiles
2025-12-15refactor(test): deprecates functions in some tests #36972glepnir1
Problem: feed_command, nvim_buf_set_option, nvim_buf_get_number, and exc_exec are marked as deprecated. Solution: Remove them from the test units in api/buffer_spec, autocmd/focus_spec, ui/input_spec, and editor/put_spec. Some test units only used a few deprecated functions, so creating a separate PR for each would be excessive. Therefore, several were combined into a single PR.
2025-02-10feat(ui): UI :detach commandJustin M. Keyes1
Problem: Cannot detach the current UI. Solution: - Introduce `:detach`. - Introduce `Channel.detach`. Co-authored-by: bfredl <bjorn.linse@gmail.com>
2024-11-14fix(tests): needing two calls to setup a screen is cringebfredl1
Before calling "attach" a screen object is just a dummy container for (row, col) values whose purpose is to be sent as part of the "attach" function call anyway. Just create the screen in an attached state directly. Keep the complete (row, col, options) config together. It is still completely valid to later detach and re-attach as needed, including to another session.
2024-04-23test: improve test conventionsdundargoc1
Specifically, functions that are run in the context of the test runner are put in module `test/testutil.lua` while the functions that are run in the context of the test session are put in `test/functional/testnvim.lua`. Closes https://github.com/neovim/neovim/issues/27004.
2024-04-10refactor(test): inject after_each differentlyLewis Russell1
2024-04-08test: improve test conventionsdundargoc1
Work on https://github.com/neovim/neovim/issues/27004.
2024-01-12test: rename (meths, funcs) -> (api, fn)Lewis Russell1
2024-01-12test: normalise nvim bridge functionsLewis Russell1
- remove helpers.cur*meths - remove helpers.nvim
2024-01-12test: do not inject vim module into global helpersLewis Russell1
2024-01-03refactor: format test/*Justin M. Keyes1
2023-04-27test: fix dependencies between test cases (#23343)zeertzjq1
Discovered using --shuffle argument of busted.
2023-04-07test: improve editor/fold_spec.lua and editor/put_spec.lua (#22916)zeertzjq1
- Close and open a new window each time so that window options have their default values in each test. - Change feed_command() to command() as the latter is faster.
2022-07-18perf(ui): eliminate spurious memory allocations for hl_attr_define eventbfredl1
2022-03-10chore: fix typos (#17331)dundargoc1
Co-authored-by: Hongyi Lyu <hongyi.lyu95@gmail.com> Co-authored-by: Gregory Anders <greg@gpanders.com> Co-authored-by: notomo <notomo.motono@gmail.com> Co-authored-by: zeertzjq <zeertzjq@outlook.com>
2022-02-09vim-patch:8.2.4242: put in Visual mode cannot be repeatedzeertzjq1
Problem: Put in Visual mode cannot be repeated. Solution: Use "P" to put without yanking the deleted text into the unnamed register. (Shougo Matsushita, closes vim/vim#9591) https://github.com/vim/vim/commit/fb55207ed17918c8a2a6cadf5ad9d5fcf686a7ab Cherry-pick get_y_previous() and set_y_previous() from patch 8.1.1736. Nvim has removed y_current, so code related to it is N/A.
2022-01-19test(put_spec): correctly order parameters to eq() (#17134)zeertzjq1
The first parameter to eq() should be the expected value, and the second parameter should be the actual value.
2021-09-17test: reorg #15698Justin M. Keyes1
Problem: Subdirectories like "visual", "insert", "normal" encourage people to separate *related* tests for no good reason. Typically the _mode_ is not the relevant topic of a test (and when it is, _then_ create an appropriate describe() or it()). Solution: - Delete the various `test/functional/<mode>/` subdirectories, move their tests to more meaningful topics. - Rename `…/normal/` to `…/editor/`. - Move or merge `…/visual/*` and `…/insert/*` tests into here where appropriate. - Rename `…/eval/` to `…/vimscript/`. - Move `…/viml/*` into here also. * test(reorg): insert/* => editor/mode_insert_spec.lua * test(reorg): cmdline/* => editor/mode_cmdline_spec.lua * test(reorg): eval core tests => eval_spec.lua