tap-parser
Advanced tools
Comparing version 2.0.0 to 2.1.0
16
index.js
@@ -122,2 +122,4 @@ // Transforms a stream of TAP into a stream of result objects | ||
this.preserveWhitespace = options.preserveWhitespace || false | ||
this.count = 0 | ||
@@ -476,3 +478,4 @@ this.pass = 0 | ||
level: this.level + 1, | ||
buffered: maybeBuffered | ||
buffered: maybeBuffered, | ||
preserveWhitespace: this.preserveWhitespace | ||
}) | ||
@@ -503,2 +506,3 @@ | ||
this.maybeChild = null | ||
this.child.name = subtestComment.substr('# Subtest: '.length).trim() | ||
@@ -533,11 +537,11 @@ // at some point, we may wish to move 100% to preferring | ||
line = this.yind + line | ||
else | ||
return | ||
} | ||
// this is a line we are processing, so emit it, but don't | ||
// emit all the whitespace, because that's just annoyingly noisy. | ||
if (line.trim()) | ||
// this is a line we are processing, so emit it | ||
if (this.preserveWhitespace || line.trim() || this.yind) | ||
this.emit('line', line) | ||
if (line === '\n') | ||
return | ||
// check to see if the line is indented. | ||
@@ -544,0 +548,0 @@ // if it is, then it's either a subtest, yaml, or garbage. |
{ | ||
"name": "tap-parser", | ||
"version": "2.0.0", | ||
"version": "2.1.0", | ||
"description": "parse the test anything protocol", | ||
@@ -15,6 +15,6 @@ "main": "index.js", | ||
"glob": "^7.0.5", | ||
"tap": "^6.3.0" | ||
"tap": "^7.0.0" | ||
}, | ||
"scripts": { | ||
"test": "tap test/*.js --cov", | ||
"test": "tap test/*.js --100", | ||
"regen-fixtures": "node scripts/generate-test.js test/fixtures/*.tap" | ||
@@ -21,0 +21,0 @@ }, |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
29424
708
191