Give docs errors a better failure message

This commit is contained in:
Nathan Sobo
2013-05-03 17:34:48 -06:00
parent da938d8212
commit ebfd8ca4c3

View File

@@ -350,7 +350,9 @@ describe "the `atom` global", ->
results.pop()
errors = parseInt results.pop().match(/\d+/)
expect(errors).toBe 0
if errors > 0
console.error results.join('\n')
throw new Error("There were errors compiling documentation. See console for details.")
coverage = parseFloat results.pop().match(/.+?%/)
expect(coverage).toBeGreaterThan 79