|
|
@ -74,7 +74,9 @@ const main = async () => { |
|
|
|
const tools = { eq, fail, wait, code, ctx } |
|
|
|
const tools = { eq, fail, wait, code, ctx } |
|
|
|
for (const [i, t] of tests.entries()) { |
|
|
|
for (const [i, t] of tests.entries()) { |
|
|
|
try { |
|
|
|
try { |
|
|
|
await t(tools) |
|
|
|
if (!await t(tools)) { |
|
|
|
|
|
|
|
throw Error('Test failed') |
|
|
|
|
|
|
|
} |
|
|
|
} catch (err) { |
|
|
|
} catch (err) { |
|
|
|
console.log(`test #${i} failed:\n${t.toString()}\n\nError:`) |
|
|
|
console.log(`test #${i} failed:\n${t.toString()}\n\nError:`) |
|
|
|
fatal(stackFmt(err, url)) |
|
|
|
fatal(stackFmt(err, url)) |
|
|
|