【发布时间】:2012-12-06 03:00:50
【问题描述】:
我正在使用 Mocha 运行许多测试。当我进行一组特定的测试时:
describe "Results Summaries", ->
before (done) ->
Testing.use("surveyplanet_test")
Testing.initialUsers -> Testing.clearResultData ->
done()
beforeEach (done) ->
Testing.redis.flushdb -> done()
describe "Multiple Choice", ->
describe "Standard Choice Selection", ->
before (done) ->
Testing.clearResultData ->
Testing.loadQuestion "standardMC", ->
Testing.loadExportData
data: summarydata.standardMC
onComplete: done
describe "Pre-Summarization", ->
before (done) ->
answer_data = {}
Testing.getMultipleTables
tables: ["answers_main"]
onComplete: (data) ->
answer_data = data
done()
它抛出错误:
结果摘要 1)“首先”钩子
✖ 340 次测试中有 1 次失败:
1) 结果摘要“首先”挂钩: 错误:超过 2000 毫秒的超时 在对象。 (/usr/local/lib/node_modules/mocha/lib/runnable.js:142:14) 在 Timer.list.ontimeout (timers.js:101:19)
有没有什么方法可以获取引发错误的我的代码的堆栈跟踪?
【问题讨论】:
标签: node.js coffeescript mocha.js