It appears that used msgpack library is not able to parse back message created
by msgpack_rpc_from_object() if nesting level is too high, so log_server_msg now
cares about msgpack_unpack_next() return value. Also error message from
server_notifications_spec.lua is not readable if something is wrong (though at
least now it does not crash when parsing deeply nested structures).
log_server_msg() in the test reports
[msgpack-rpc] nvim -> client(1) [error] "parse error"
This removes some stack overflows in new test regarding deeply nested variables.
Now in place of crashing vim_to_object/msgpack_rpc_from_object/etc it crashes
clear_tv with stack overflow.
This ought to prevent stack overflow, but I do not see this actually working:
*lua* code crashes with stack overflow when trying to deserialize msgpack from
Neovim, Neovim is fine even if nesting level is increased 100x (though test
becomes very slow); not sure how recursive function may survive this. So it
looks like there are currently only two positive effects:
1. NULL lists are returned as empty (#4596).
2. Functional tests are slightly more fast. Very slightly. Checked for Release
build for test/functional/eval tests because benchmarking of debug mode is
not very useful.
add tests for synIDattr() with [fg|bg|sp]#
add tests for synIDattr and various #RGB colors
synIDattr: test for ui_rgb_attached()
test: fix tests for synIDattr fg/bg/sp
Problem: Can only get the directory of the current window.
Solution: Add window and tab arguments to getcwd() and haslocaldir().
(Thinca, Hirohito Higashi)
c970330676
menu_spec.lua yanks to the clipboard, but never pastes from it. This
can leave a child xsel process waiting around for something to paste the
content, causing the test process to hang.
Since the test isn't explicitly trying to exercise the clipboard, simply
use the default register.
When skipping these test blocks they may error out:
Error → test/functional/shell/viml_system_spec.lua @ 154
system() with output containing NULs setup
./test/functional/helpers.lua:75: attempt to index upvalue 'session' (a nil value)
stack traceback:
./test/functional/helpers.lua:75: in function 'request'
./test/functional/helpers.lua:166: in function 'nvim_feed'
./test/functional/helpers.lua:195: in function 'feed'
test/functional/shell/viml_system_spec.lua:14: in function <test/functional/shell/viml_system_spec.lua:13>
Error → test/functional/shell/viml_system_spec.lua @ 155
system() with output containing NULs teardown
./test/functional/helpers.lua:75: attempt to index upvalue 'session' (a nil value)
stack traceback:
./test/functional/helpers.lua:75: in function 'eval'
test/functional/shell/viml_system_spec.lua:21: in function <test/functional/shell/viml_system_spec.lua:20>
It is otherwise impossible to determine which test failed sanitizer/valgrind
check. test/functional/helpers.lua module return was changed so that tests which
do not provide after_each function to get new check will automatically fail.
Problem: Autocommands triggered by quickfix cannot always get the current
title value.
Solution: Call qf_fill_buffer() later. (Christian Brabandt)
6920c72d4d
Helped by @mhinz
Add both a test for cwd=/ and cwd=/tmp/nvim.XXXXX, to make sure that we
don't have regressions in cwd handling.
Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>