aboutsummaryrefslogtreecommitdiff
path: root/test/functional/treesitter/language_spec.lua
diff options
context:
space:
mode:
authorJosh Rahm <rahm@google.com>2022-10-11 19:00:34 +0000
committerJosh Rahm <rahm@google.com>2022-10-11 19:00:34 +0000
commitc367400b73d207833d51e09d663f969ffab37531 (patch)
treebc26006d942509a92b514107f9d8dca6d3911128 /test/functional/treesitter/language_spec.lua
parent4066fa85abef16fa23c30e94dc4d2bfb3b9c4545 (diff)
parent760b399f6c0c6470daa0663752bd22886997f9e6 (diff)
downloadrneovim-c367400b73d207833d51e09d663f969ffab37531.tar.gz
rneovim-c367400b73d207833d51e09d663f969ffab37531.tar.bz2
rneovim-c367400b73d207833d51e09d663f969ffab37531.zip
Merge remote-tracking branch 'upstream/master' into colorcolchar
Diffstat (limited to 'test/functional/treesitter/language_spec.lua')
-rw-r--r--test/functional/treesitter/language_spec.lua12
1 files changed, 2 insertions, 10 deletions
diff --git a/test/functional/treesitter/language_spec.lua b/test/functional/treesitter/language_spec.lua
index 8e9941d797..ed84dedb5a 100644
--- a/test/functional/treesitter/language_spec.lua
+++ b/test/functional/treesitter/language_spec.lua
@@ -6,7 +6,6 @@ local command = helpers.command
local exec_lua = helpers.exec_lua
local pcall_err = helpers.pcall_err
local matches = helpers.matches
-local pending_c_parser = helpers.pending_c_parser
local insert = helpers.insert
before_each(clear)
@@ -28,15 +27,11 @@ describe('treesitter language API', function()
eq("Error executing lua: .../language.lua:0: no parser for 'borklang' language, see :help treesitter-parsers",
pcall_err(exec_lua, "parser = vim.treesitter.inspect_language('borklang')"))
- if not pending_c_parser(pending) then
- matches("Error executing lua: Failed to load parser: uv_dlsym: .+",
- pcall_err(exec_lua, 'vim.treesitter.require_language("c", nil, false, "borklang")'))
- end
+ matches("Error executing lua: Failed to load parser: uv_dlsym: .+",
+ pcall_err(exec_lua, 'vim.treesitter.require_language("c", nil, false, "borklang")'))
end)
it('inspects language', function()
- if pending_c_parser(pending) then return end
-
local keys, fields, symbols = unpack(exec_lua([[
local lang = vim.treesitter.inspect_language('c')
local keys, symbols = {}, {}
@@ -76,7 +71,6 @@ describe('treesitter language API', function()
end)
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")
-- Should not throw an error when filetype is c
eq('c', exec_lua("return vim.treesitter.get_parser(0):lang()"))
@@ -87,7 +81,6 @@ describe('treesitter language API', function()
end)
it('retrieve the tree given a range', function ()
- if pending_c_parser(pending) then return end
insert([[
int main() {
int x = 3;
@@ -102,7 +95,6 @@ describe('treesitter language API', function()
end)
it('retrieve the node given a range', function ()
- if pending_c_parser(pending) then return end
insert([[
int main() {
int x = 3;