summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/diagnostics/type-check.lua21
1 files changed, 14 insertions, 7 deletions
diff --git a/test/diagnostics/type-check.lua b/test/diagnostics/type-check.lua
index 3e4584c0..b9681d78 100644
--- a/test/diagnostics/type-check.lua
+++ b/test/diagnostics/type-check.lua
@@ -153,13 +153,6 @@ x = 1.0
]]
TEST [[
----@type integer
-local x = 0
-
-<!x!> = 1.0
-]]
-
-TEST [[
---@class A
local t = {}
@@ -317,5 +310,19 @@ local function f(x) end
f(<!true!>)
]]
+TEST [[
+---@type integer
+local x
+
+x = 1.0
+]]
+
+TEST [[
+---@type integer
+local x
+
+<!x!> = 1.5
+]]
+
config.remove(nil, 'Lua.diagnostics.disable', 'unused-local')
config.remove(nil, 'Lua.diagnostics.disable', 'undefined-global')