mirror of
https://github.com/neovim/neovim.git
synced 2026-05-05 13:35:02 +00:00
test: simplify platform detection (#21020)
Extend the capabilities of is_os to detect more platforms such as
freebsd and openbsd. Also remove `iswin()` helper function as it can be
replaced by `is_os("win")`.
This commit is contained in:
@@ -5,7 +5,7 @@ local eq = helpers.eq
|
||||
local insert = helpers.insert
|
||||
local exec_lua = helpers.exec_lua
|
||||
local feed = helpers.feed
|
||||
local iswin = helpers.iswin
|
||||
local is_os = helpers.is_os
|
||||
local skip = helpers.skip
|
||||
|
||||
before_each(clear)
|
||||
@@ -684,7 +684,7 @@ int x = INT_MAX;
|
||||
end)
|
||||
|
||||
it("should not inject bad languages", function()
|
||||
skip(iswin())
|
||||
skip(is_os('win'))
|
||||
exec_lua([=[
|
||||
vim.treesitter.add_directive("inject-bad!", function(match, _, _, pred, metadata)
|
||||
metadata.language = "{"
|
||||
|
||||
Reference in New Issue
Block a user