aboutsummaryrefslogtreecommitdiff
path: root/test/functional/terminal/scrollback_spec.lua
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2024-12-19 07:07:04 -0800
committerGitHub <noreply@github.com>2024-12-19 07:07:04 -0800
commit8ef41f590224dfeea2e51d9fec150e363fd72ee0 (patch)
tree2c9879066ef7e70dc1d178d46e2048bf1470f818 /test/functional/terminal/scrollback_spec.lua
parenta5a4149e9754a96c063a357c18397aa7906edf53 (diff)
downloadrneovim-8ef41f590224dfeea2e51d9fec150e363fd72ee0.tar.gz
rneovim-8ef41f590224dfeea2e51d9fec150e363fd72ee0.tar.bz2
rneovim-8ef41f590224dfeea2e51d9fec150e363fd72ee0.zip
feat(jobs): jobstart(…,{term=true}), deprecate termopen() #31343
Problem: `termopen` has long been a superficial wrapper around `jobstart`, and has no real purpose. Also, `vim.system` and `nvim_open_term` presumably will replace all features of `jobstart` and `termopen`, so centralizing the logic will help with that. Solution: - Introduce `eval/deprecated.c`, where all deprecated eval funcs will live. - Introduce "term" flag of `jobstart`. - Deprecate `termopen`.
Diffstat (limited to 'test/functional/terminal/scrollback_spec.lua')
-rw-r--r--test/functional/terminal/scrollback_spec.lua6
1 files changed, 4 insertions, 2 deletions
diff --git a/test/functional/terminal/scrollback_spec.lua b/test/functional/terminal/scrollback_spec.lua
index 0de7873200..804c5367eb 100644
--- a/test/functional/terminal/scrollback_spec.lua
+++ b/test/functional/terminal/scrollback_spec.lua
@@ -355,7 +355,9 @@ describe(':terminal prints more lines than the screen height and exits', functio
it('will push extra lines to scrollback', function()
clear()
local screen = Screen.new(30, 7, { rgb = false })
- command(("call termopen(['%s', '10']) | startinsert"):format(testprg('tty-test')))
+ command(
+ ("call jobstart(['%s', '10'], {'term':v:true}) | startinsert"):format(testprg('tty-test'))
+ )
screen:expect([[
line6 |
line7 |
@@ -623,7 +625,7 @@ describe('pending scrollback line handling', function()
local bufnr = vim.api.nvim_create_buf(false, true)
local args = ...
vim.api.nvim_buf_call(bufnr, function()
- vim.fn.termopen(args)
+ vim.fn.jobstart(args, { term = true })
end)
vim.api.nvim_win_set_buf(0, bufnr)
vim.cmd('startinsert')