summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-01-19 15:35:46 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-01-19 15:35:46 +0800
commitd6859305513099d125f6dad69cb35f29b796bebf (patch)
tree033a54f1c569db5eaacde278abfe0a1e6b7b320f
parent282ac2d03f6aa686cc5510dfdce5ad5a3df625bb (diff)
downloadlua-language-server-d6859305513099d125f6dad69cb35f29b796bebf.zip
dont test cross platform
-rw-r--r--test.lua33
-rw-r--r--test/crossfile/definition.lua7
2 files changed, 19 insertions, 21 deletions
diff --git a/test.lua b/test.lua
index eae21de7..327cb7d6 100644
--- a/test.lua
+++ b/test.lua
@@ -79,24 +79,21 @@ local function main()
log.print = true
- for _, os in ipairs {'Windows', 'Linux', 'macOS'} do
- require 'bee.platform'.OS = os
- ---@async
- lclient():start(function (client)
- client:registerFakers()
- client:initialize()
-
- ws.awaitReady()
-
- print('Loaded files in', os)
- for uri in files.eachFile() do
- print(uri)
- end
- print('===============')
-
- testAll()
- end)
- end
+ ---@async
+ lclient():start(function (client)
+ client:registerFakers()
+ client:initialize()
+
+ ws.awaitReady()
+
+ print('Loaded files in', os)
+ for uri in files.eachFile() do
+ print(uri)
+ end
+ print('===============')
+
+ testAll()
+ end)
test 'tclient'
test 'full'
diff --git a/test/crossfile/definition.lua b/test/crossfile/definition.lua
index ad26e96f..ecd6f98e 100644
--- a/test/crossfile/definition.lua
+++ b/test/crossfile/definition.lua
@@ -688,8 +688,8 @@ TEST {
}
}
-local originOS = platform.OS
-platform.OS = 'Linux'
+
+if platform.OS == 'Linux' then
TEST {
{
@@ -742,7 +742,8 @@ TEST {
]]
}
}
-platform.OS = originOS
+
+end
local originRuntimePath = config.get(nil, 'Lua.runtime.path')
config.set(nil, 'Lua.runtime.path', {