summaryrefslogtreecommitdiff
path: root/tests/runner.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2024-04-09 09:37:46 +0800
committerGitHub <[email protected]>2024-04-09 09:37:46 +0800
commitc729be0bb01b41b2cdc67f5b5713da239c9ea9a6 (patch)
tree0fde774547602aa4a9fd1ce3866c8cbed71f1854 /tests/runner.lua
parent15af62b0406caefc71ad7fa01c41f29a017759bb (diff)
parent19b67001ad77668b555a1213bc6d473bc35318aa (diff)
Merge pull request #4947 from xmake-io/runjobs
Improve runjobs
Diffstat (limited to 'tests/runner.lua')
-rw-r--r--tests/runner.lua11
1 files changed, 7 insertions, 4 deletions
diff --git a/tests/runner.lua b/tests/runner.lua
index c99142170..b3d578a6f 100644
--- a/tests/runner.lua
+++ b/tests/runner.lua
@@ -50,11 +50,14 @@ function main(script)
end,
catch
{
- function (error)
- if not error:find("aborting because of ") then
- context:print_error(error, v, "unhandled error")
+ function (errors)
+ if errors then
+ errors = tostring(errors)
+ end
+ if errors and not errors:find("aborting because of ") then
+ context:print_error(errors, v, "unhandled error")
else
- raise(error)
+ raise(errors)
end
end
}