neovim/test/functional/lua
TJ DeVries 398201cfab
lua: Fix crash on unprotected lua errors (#12658)
Can be reproduced with a script like this:

-- in some lua file
vim.fn.timer_start(10, function() error("uh....") end)

-- will cause neovim to crash with the following error.
PANIC: unprotected error in call to Lua API
        (nlua_CFunction_func_call failed.)

After this, it will instead print the error message
from the top of the stack, like so.

tmp/error_nvim.lua:10: uh...

Also added an example test. Previously this test
caused the embedded nvim to panic.
2020-07-19 17:16:48 -04:00
..
api_spec.lua API: include invalid buffer/window/tabpage in error message (#11712) 2020-01-14 09:21:10 +01:00
buffer_updates_spec.lua doc: fix typos [ci skip] #11787 2020-01-30 22:56:34 -08:00
commands_spec.lua API: include invalid buffer/window/tabpage in error message (#11712) 2020-01-14 09:21:10 +01:00
loop_spec.lua lua: add vim.in_fast_event() to check if we are in a luv callback 2019-08-05 13:57:24 +02:00
luaeval_spec.lua lua: Fix crash on unprotected lua errors (#12658) 2020-07-19 17:16:48 -04:00
overrides_spec.lua API: rename nvim_execute_lua => nvim_exec_lua 2019-12-02 22:06:42 -08:00
treesitter_spec.lua treesitter: update test to show overlapping works 2020-07-10 17:16:24 +02:00
uri_spec.lua Change uri_to_fname to not convert non-file URIs (#12351) 2020-05-22 01:17:21 +09:00
vim_spec.lua test: remove flaky unhelpful test 2020-06-06 01:11:12 +02:00