Skip to content

Commit 44684bf

Browse files
committed
ci: skip failing test in old nvim versions
1 parent e749260 commit 44684bf

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tests/treesitter_spec.lua

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,17 @@ local function list_files(dir)
2323
end
2424

2525
describe("treesitter", function()
26+
local skip_tests = {}
27+
if vim.fn.has("nvim-0.11") == 0 then
28+
-- ABI version mismatch
29+
table.insert(skip_tests, "enforce_test.c")
30+
end
31+
2632
for _, filename in ipairs(list_files("tests/treesitter")) do
33+
if vim.tbl_contains(skip_tests, filename) then
34+
print("Skipping test", filename)
35+
goto continue
36+
end
2737
local filepath = "./tests/treesitter/" .. filename
2838
local basename = vim.fn.fnamemodify(filename, ":r")
2939
local symbols_file = "./tests/symbols/" .. basename .. ".json"
@@ -38,6 +48,7 @@ describe("treesitter", function()
3848
util.test_file_symbols("markdown", filepath, "./tests/symbols/markdown_backend.json")
3949
end)
4050
end
51+
::continue::
4152
end
4253

4354
util.test_file_symbols("man", "./tests/man_test.txt", "./tests/symbols/man.json")

0 commit comments

Comments
 (0)