33 lines
1.3 KiB
Diff
33 lines
1.3 KiB
Diff
commit 95c374348a50bd1b1a07a4f82f7f630d240bf843
|
|
Author: Tom Hughes <tom@compton.nu>
|
|
Date: Sun Nov 22 00:43:09 2015 +0000
|
|
|
|
Fix test for changes in junit reporter
|
|
|
|
I'm not clear why, but the junit reporter seems to report one
|
|
error and one failure now instead of two errors.
|
|
|
|
diff --git a/test/nodeunit_test.js b/test/nodeunit_test.js
|
|
index a5f8cbf..6ef069e 100644
|
|
--- a/test/nodeunit_test.js
|
|
+++ b/test/nodeunit_test.js
|
|
@@ -62,7 +62,7 @@ exports.nodeunit = {
|
|
});
|
|
},
|
|
junit: function(test) {
|
|
- test.expect(4);
|
|
+ test.expect(5);
|
|
grunt.util.spawn({
|
|
grunt: true,
|
|
args: ['test-junit:fail', '--no-color'],
|
|
@@ -73,7 +73,8 @@ exports.nodeunit = {
|
|
var junitContents = grunt.util.normalizelf(grunt.file.read(junitFile));
|
|
|
|
test.ok(junitContents.indexOf('<testsuite name="fail.js"') !== -1, 'testsuite element');
|
|
- test.ok(junitContents.indexOf('errors="2"') !== -1, 'Two errors detected');
|
|
+ test.ok(junitContents.indexOf('errors="1"') !== -1, 'One errore detected');
|
|
+ test.ok(junitContents.indexOf('failures="1"') !== -1, 'One failure detected');
|
|
test.ok(junitContents.indexOf('AssertionError: this value should be truthy') !== -1, 'Assertion');
|
|
test.ok(junitContents.indexOf('fail - failSupertestError') !== -1, 'Failure message');
|
|
|