Merge pull request #920 from Blizzard/selftest-fix

small fix in self-test module.
This commit is contained in:
Tom van Dijck 2017-10-13 09:08:00 -07:00 committed by GitHub
commit 5a0e2c8cb1

View File

@ -59,14 +59,16 @@
local passed = 0 local passed = 0
local failed = 0 local failed = 0
for testName, testFunction in pairs(test.suite) do if test.suite ~= nil then
test.testName = testName for testName, testFunction in pairs(test.suite) do
test.testFunction = testFunction test.testName = testName
test.testFunction = testFunction
if m.isValid(test) and not m.isSuppressed(test.suiteName .. "." .. test.testName) then if m.isValid(test) and not m.isSuppressed(test.suiteName .. "." .. test.testName) then
local np, nf = _.runTest(test) local np, nf = _.runTest(test)
passed = passed + np passed = passed + np
failed = failed + nf failed = failed + nf
end
end end
end end