Skip to content
This repository has been archived by the owner on Aug 18, 2021. It is now read-only.

Commit

Permalink
Re-add parseNoPatch function (accidentally removed) (#557)
Browse files Browse the repository at this point in the history
  • Loading branch information
not-an-aardvark committed Dec 24, 2017
1 parent dbc6546 commit bba9d00
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/index.js
Expand Up @@ -15,3 +15,7 @@ exports.parseForESLint = function(code, options) {
patched = true;
return { ast: require("./parse-with-patch")(code, options) };
};

exports.parseNoPatch = function(code, options) {
return require("./parse")(code, options);
};
9 changes: 9 additions & 0 deletions test/babel-eslint.js
Expand Up @@ -531,3 +531,12 @@ describe("babylon-to-esprima", () => {
});
});
});

describe("Public API", () => {
it("exports a parseNoPatch function", () => {
assertImplementsAST(
espree.parse("foo"),
babelEslint.parseNoPatch("foo", {})
);
});
});

0 comments on commit bba9d00

Please sign in to comment.