Skip to content

Commit

Permalink
fix unit tests in compat
Browse files Browse the repository at this point in the history
  • Loading branch information
fasttime committed Sep 8, 2024
1 parent 133ee16 commit 9d129e7
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions packages/compat/tests/fixup-rules.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
//-----------------------------------------------------------------------------

import assert from "node:assert";
import path from "node:path";
import {
fixupRule,
fixupPluginRules,
Expand Down Expand Up @@ -133,7 +134,7 @@ describe("@eslint/backcompat", () => {
const linter = new Linter();
const code = "var foo = () => 123; function bar() { return 123; }";
const messages = linter.verify(code, config, {
filename: "test.js",
filename: path.resolve("test.js"),
});

assert.deepStrictEqual(
Expand Down Expand Up @@ -203,7 +204,7 @@ describe("@eslint/backcompat", () => {
const code =
"var foo = () => 123; function bar() { return 123; }";
const messages = linter.verify(code, config, {
filename: "test.js",
filename: path.resolve("test.js"),
});

assert.deepStrictEqual(
Expand Down Expand Up @@ -283,7 +284,7 @@ describe("@eslint/backcompat", () => {
const code =
"var foo = () => 123; function bar() { for (const x of y) { foo(); } }";
const messages = linter.verify(code, config, {
filename: "test.js",
filename: path.resolve("test.js"),
});

assert.deepStrictEqual(
Expand Down Expand Up @@ -507,7 +508,7 @@ describe("@eslint/backcompat", () => {
},
},
{
filename: "test.js",
filename: path.resolve("test.js"),
},
);

Expand Down Expand Up @@ -641,7 +642,7 @@ describe("@eslint/backcompat", () => {
const code =
"var foo = () => 123; function bar() { return 123; }";
const messages = linter.verify(code, fixupConfigRules(config), {
filename: "test.js",
filename: path.resolve("test.js"),
});

assert.deepStrictEqual(
Expand Down

0 comments on commit 9d129e7

Please sign in to comment.