mirror of
https://github.com/neovim/neovim
synced 2025-07-17 17:51:48 +00:00
test(ts): skip test if C parser is not available
(cherry picked from commit 6b0595d7cc
)
This commit is contained in:
committed by
github-actions[bot]
parent
d317cb2322
commit
bd3bb128c0
@ -70,6 +70,7 @@ describe('treesitter API', function()
|
|||||||
end)
|
end)
|
||||||
|
|
||||||
it('checks if vim.treesitter.get_parser tries to create a new parser on filetype change', function ()
|
it('checks if vim.treesitter.get_parser tries to create a new parser on filetype change', function ()
|
||||||
|
if pending_c_parser(pending) then return end
|
||||||
command("set filetype=c")
|
command("set filetype=c")
|
||||||
-- Should not throw an error when filetype is c
|
-- Should not throw an error when filetype is c
|
||||||
eq('c', exec_lua("return vim.treesitter.get_parser(0):lang()"))
|
eq('c', exec_lua("return vim.treesitter.get_parser(0):lang()"))
|
||||||
|
Reference in New Issue
Block a user