Skip to content

Commit 086fb0e

Browse files
committed
Fix failing JSDocParser tests
(cherry picked from commit ae27b89)
1 parent 7dcdb82 commit 086fb0e

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

tests/cases/unittests/jsDocParsing.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ module ts {
1111
assert.isTrue(typeAndDiagnostics && typeAndDiagnostics.diagnostics.length === 0);
1212

1313
let result = Utils.sourceFileToJSON(typeAndDiagnostics.jsDocTypeExpression.type);
14+
15+
// Remove the parserContextFlags from the comparison
16+
result = result.replace(/\,\n\s+\"parserContextFlags\": \"JavaScriptFile\"/g, "");
1417
assert.equal(result, expected);
1518
}
1619

@@ -998,7 +1001,10 @@ module ts {
9981001
? JSON.parse(Utils.sourceFileToJSON(v))
9991002
: v;
10001003
}, 4);
1001-
1004+
1005+
// Remove the parserContextFlags from the comparison
1006+
result = result.replace(/\,\n\s+\"parserContextFlags\": \"JavaScriptFile\"/g, "");
1007+
10021008
if (result !== expected) {
10031009
// Turn on a human-readable diff
10041010
if (typeof require !== 'undefined') {

0 commit comments

Comments
 (0)