summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/projects/c++/modules/test_base.lua2
-rw-r--r--tests/runner.lua11
2 files changed, 8 insertions, 5 deletions
diff --git a/tests/projects/c++/modules/test_base.lua b/tests/projects/c++/modules/test_base.lua
index 804947f08..219901c63 100644
--- a/tests/projects/c++/modules/test_base.lua
+++ b/tests/projects/c++/modules/test_base.lua
@@ -48,7 +48,7 @@ function main(t)
os.exec("xmake f -c --yes")
_build()
elseif is_subhost("msys") then
- os.exec("xmake f -c -p mingw -vD --yes")
+ os.exec("xmake f -c -p mingw --yes")
_build()
elseif is_host("linux") then
local gcc = find_tool("gcc", {version = true})
diff --git a/tests/runner.lua b/tests/runner.lua
index c99142170..4558c38ce 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
+ error = tostring(errors)
+ end
+ if not errors:find("aborting because of ") then
+ context:print_error(errors, v, "unhandled error")
else
- raise(error)
+ raise(errors)
end
end
}