summaryrefslogtreecommitdiff
path: root/test/diagnostics/init.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2021-07-01 20:00:22 +0800
committer最萌小汐 <sumneko@hotmail.com>2021-07-01 20:00:22 +0800
commit71e3ff51d3fb21f3e78a3948809ce4ae92613de2 (patch)
tree936752e4377a48281cd4b1752b53bcda1352d0bb /test/diagnostics/init.lua
parent8077e3e08f2dd799ef9b5335005f1bf85d6340cd (diff)
downloadlua-language-server-71e3ff51d3fb21f3e78a3948809ce4ae92613de2.zip
cleanup
Diffstat (limited to 'test/diagnostics/init.lua')
-rw-r--r--test/diagnostics/init.lua14
1 files changed, 7 insertions, 7 deletions
diff --git a/test/diagnostics/init.lua b/test/diagnostics/init.lua
index cb314691..29e80c7b 100644
--- a/test/diagnostics/init.lua
+++ b/test/diagnostics/init.lua
@@ -4,7 +4,7 @@ local config = require 'config'
local util = require 'utility'
local define = require 'proto.define'
-config.Lua.diagnostics.neededFileStatus['deprecated'] = 'Any'
+config.get 'Lua.diagnostics.neededFileStatus'['deprecated'] = 'Any'
rawset(_G, 'TEST', true)
@@ -206,7 +206,7 @@ local _ENV = { print = print }
print(1)
]]
-config.Lua.diagnostics.disable['undefined-env-child'] = true
+config.get 'Lua.diagnostics.disable'['undefined-env-child'] = true
TEST [[
_ENV = nil
<!GLOBAL!> = 1 --> _ENV.GLOBAL = 1
@@ -232,7 +232,7 @@ GLOBAL = 1
_ENV = nil
]]
-config.Lua.diagnostics.disable['undefined-env-child'] = nil
+config.get 'Lua.diagnostics.disable'['undefined-env-child'] = nil
TEST [[
<!print()
('string')!>:sub(1, 1)
@@ -344,17 +344,17 @@ return [[
]]
]=]
-config.Lua.diagnostics.disable['close-non-object'] = true
+config.get 'Lua.diagnostics.disable'['close-non-object'] = true
TEST [[
local _ <close> = function () end
]]
-config.Lua.diagnostics.disable['close-non-object'] = nil
+config.get 'Lua.diagnostics.disable'['close-non-object'] = nil
TEST [[
local _ <close> = <!1!>
]]
-config.Lua.diagnostics.disable['unused-local'] = true
+config.get 'Lua.diagnostics.disable'['unused-local'] = true
TEST [[
local f = <!function () end!>
]]
@@ -367,7 +367,7 @@ TEST [[
local <!function f() end!>
]]
-config.Lua.diagnostics.disable['unused-local'] = nil
+config.get 'Lua.diagnostics.disable'['unused-local'] = nil
TEST [[
local mt, x
function mt:m()