Commit 935c4572 authored by Craig Barnes's avatar Craig Barnes

Improve verbose output of test/compare.lua

parent 6735c605
Pipeline #15900180 passed with stage
in 49 seconds
......@@ -59,8 +59,7 @@ local function compare(t1, t2)
seen[index] = true
end
elseif verbose then
local index = keys:tostring(k)
stderr:write(("OK: %s\n"):format(index))
stderr:write(" OK: ", keys:tostring(k), "\n")
end
end
return true
......@@ -74,5 +73,9 @@ local t1 = assert(ltcn.parse(text, filename))
local fn = assert(load("return" .. text, "=" .. filename, "t"))
local t2 = assert(fn())
if verbose then
stderr:write("\n", filename, "\n", ("-"):rep(#filename), "\n")
end
compare(t1, t2)
compare(t2, t1)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment