summaryrefslogtreecommitdiff
path: root/server/test
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2018-12-13 21:06:53 +0800
committer最萌小汐 <sumneko@hotmail.com>2018-12-13 21:06:53 +0800
commit1b8f1893ed1f0ae8495d171488c84984f67fc8ad (patch)
treec561ccc705703718a1e4401ea742e401520a42c7 /server/test
parentf1da693a59a223c781c757cf22836b99f28735d6 (diff)
downloadlua-language-server-1b8f1893ed1f0ae8495d171488c84984f67fc8ad.zip
修改测试
Diffstat (limited to 'server/test')
-rw-r--r--server/test/type_inference/init.lua14
1 files changed, 13 insertions, 1 deletions
diff --git a/server/test/type_inference/init.lua b/server/test/type_inference/init.lua
index 36e28aec..8f5909c0 100644
--- a/server/test/type_inference/init.lua
+++ b/server/test/type_inference/init.lua
@@ -89,10 +89,22 @@ TEST 'integer' [[
<?x?> = ~ y
]]
-TEST 'boolean' [[
+TEST 'number' [[
+local a = true
+local b = 1
<?x?> = a and b
]]
+TEST 'number' [[
+local a = false
+local b = 1
+<?x?> = a or b
+]]
+
+TEST 'boolean' [[
+<?x?> = a == b
+]]
+
TEST 'integer' [[
<?x?> = a << b
]]