nodeunit icon indicating copy to clipboard operation
nodeunit copied to clipboard

junit reporter always have empty xml files with 0.6.2 worked good with 0.5.5

Open pmlopes opened this issue 14 years ago • 1 comments

Hi,

I've a couple of nested tests that were being executed as expected with 0.5.5 but with 0.6.2 i always get an empty xml file with the junit reporter.

I notice that with 0.6.2 the console does not even write FAILURES: x/y assertions while it did with 0.5.5.

Furthermore i added a console.log to the end of the junit reporter code and is seems that the rendered template is broken the output is not valid XML:

Writing /Users/me/Projects/p/logs/models.test.xml

  <testcase name="models - user - test1">

  </testcase>


  <testcase name="models - user - test2">

  </testcase>


  <testcase name="models - user - test3">

  </testcase>


  <testcase name="models - user - test4">

      <failure message="">
        AssertionError: null === 'User has no current blog'
at Object.strictEqual (/Users/me/Projects/p/node_modules/nodeunit/lib/types.js:83:39)
at /Users/me/Projects/p/test/models/User.test.js:67:14
at model.getBlog (/Users/me/Projects/p/models/User.js:569:5)
at Promise.&lt;anonymous&gt; (/Users/me/Projects/p/test/models/

The output ends here. I guess the template engine crashed or soemthing...

pmlopes avatar Nov 02 '11 14:11 pmlopes

+1

Quite frustrating.

howardabrams avatar Feb 07 '12 09:02 howardabrams