Skip to content

Commit

Permalink
Check
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolo-ribaudo committed Oct 24, 2021
1 parent 7168c3d commit 7e2265b
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions eslint/babel-eslint-parser/test/index.js
Expand Up @@ -129,6 +129,19 @@ describe("Babel and Espree", () => {

espree7 = require(espree7Path);
espree8 = require(espree8Path);

const espree7pkg = require(require.resolve("espree/package.json", {
paths: [path.dirname(require.resolve("eslint"))],
}));
const espree8pkg = require(require.resolve("espree/package.json", {
paths: [path.dirname(require.resolve("eslint-8"))],
}));
if (!espree7pkg.version.startsWith("7.")) {
throw new Error(`Expected espree 7, but found ${espree7pkg.version}`);
}
if (!espree8pkg.version.startsWith("9.")) {
throw new Error(`Expected espree 9, but found ${espree8pkg.version}`);
}
});

describe("compatibility", () => {
Expand Down

0 comments on commit 7e2265b

Please sign in to comment.