Skip to content

Commit

Permalink
Add unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
wojtekmaj committed Jul 2, 2024
1 parent 78e9508 commit 9b92579
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/rules/one-level/element-types.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,18 @@ const test = (settings, options, errorMessages) => {
},
],
},
// Can import fs module
{
filename: absoluteFilePath("modules/module-a/ModuleA.js"),
code: "import fs from 'fs'",
options,
},
// Can import node:fs module
{
filename: absoluteFilePath("modules/module-a/ModuleA.js"),
code: "import fs from 'node:fs'",
options,
},
],
invalid: [
// Helpers can't import another if everything is disallowed
Expand Down

0 comments on commit 9b92579

Please sign in to comment.