Skip to content

Commit 18ffa24

Browse files
committed
chore: correct incorrect tests
1 parent 932a2fd commit 18ffa24

File tree

1 file changed

+42
-38
lines changed

1 file changed

+42
-38
lines changed

tests/lib/rules/no-unsupported-features/node-builtins.js

Lines changed: 42 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -5478,7 +5478,7 @@ new RuleTester({ languageOptions: { sourceType: "module" } }).run(
54785478
}
54795479
}),
54805480
...[
5481-
{ version: "22.0.0" },
5481+
{ version: "22.16.0" },
54825482
{ version: "21.2.0" },
54835483
{ version: "20.11.0" },
54845484
{ version: "20.10.0", ignores: ["import.meta.dirname"] },
@@ -5490,7 +5490,7 @@ new RuleTester({ languageOptions: { sourceType: "module" } }).run(
54905490
}
54915491
}),
54925492
...[
5493-
{ version: "22.0.0" },
5493+
{ version: "22.16.0" },
54945494
{ version: "21.2.0" },
54955495
{ version: "20.11.0" },
54965496
{ version: "20.10.0", ignores: ["import.meta.filename"] },
@@ -5545,46 +5545,50 @@ new RuleTester({ languageOptions: { sourceType: "module" } }).run(
55455545
],
55465546
}
55475547
}),
5548-
...[{ version: "21.1.0" }, { version: "20.10.0" }].map(
5549-
option => {
5550-
return {
5551-
code: "import.meta.dirname;",
5552-
options: [option],
5553-
languageOptions: { ecmaVersion: "latest" },
5554-
errors: [
5555-
{
5556-
messageId: "not-supported-till",
5557-
data: {
5558-
name: "import.meta.dirname",
5559-
supported:
5560-
"21.2.0 (backported: ^20.11.0)",
5561-
version: option.version,
5562-
},
5548+
...[
5549+
{ version: "22.0.0" },
5550+
{ version: "21.1.0" },
5551+
{ version: "20.10.0" },
5552+
].map(option => {
5553+
return {
5554+
code: "import.meta.dirname;",
5555+
options: [option],
5556+
languageOptions: { ecmaVersion: "latest" },
5557+
errors: [
5558+
{
5559+
messageId: "not-supported-till",
5560+
data: {
5561+
name: "import.meta.dirname",
5562+
supported:
5563+
"22.16.0 (backported: ^21.2.0, ^20.11.0)",
5564+
version: option.version,
55635565
},
5564-
],
5565-
}
5566+
},
5567+
],
55665568
}
5567-
),
5568-
...[{ version: "21.1.0" }, { version: "20.10.0" }].map(
5569-
option => {
5570-
return {
5571-
code: "import.meta.filename;",
5572-
options: [option],
5573-
languageOptions: { ecmaVersion: "latest" },
5574-
errors: [
5575-
{
5576-
messageId: "not-supported-till",
5577-
data: {
5578-
name: "import.meta.filename",
5579-
supported:
5580-
"21.2.0 (backported: ^20.11.0)",
5581-
version: option.version,
5582-
},
5569+
}),
5570+
...[
5571+
{ version: "22.0.0" },
5572+
{ version: "21.1.0" },
5573+
{ version: "20.10.0" },
5574+
].map(option => {
5575+
return {
5576+
code: "import.meta.filename;",
5577+
options: [option],
5578+
languageOptions: { ecmaVersion: "latest" },
5579+
errors: [
5580+
{
5581+
messageId: "not-supported-till",
5582+
data: {
5583+
name: "import.meta.filename",
5584+
supported:
5585+
"22.16.0 (backported: ^21.2.0, ^20.11.0)",
5586+
version: option.version,
55835587
},
5584-
],
5585-
}
5588+
},
5589+
],
55865590
}
5587-
),
5591+
}),
55885592
],
55895593
},
55905594

0 commit comments

Comments
 (0)