patch 8.1.2080: the terminal API is limited and can't be disabled
Problem: The terminal API is limited and can't be disabled.
Solution: Add term_setapi() to set the function prefix. (Ozaki Kiichi,
closes #2907)
diff --git a/src/testdir/term_util.vim b/src/testdir/term_util.vim
index 1cfac0e..4eaf6d8 100644
--- a/src/testdir/term_util.vim
+++ b/src/testdir/term_util.vim
@@ -61,11 +61,16 @@
let cmd = GetVimCommandCleanTerm() .. a:arguments
- let buf = term_start(cmd, {
+ let options = {
\ 'curwin': 1,
\ 'term_rows': rows,
\ 'term_cols': cols,
- \ })
+ \ }
+ " Accept other options whose name starts with 'term_'.
+ call extend(options, filter(copy(a:options), 'v:key =~# "^term_"'))
+
+ let buf = term_start(cmd, options)
+
if &termwinsize == ''
" in the GUI we may end up with a different size, try to set it.
if term_getsize(buf) != [rows, cols]