Skip to content

Commit

Permalink
sort rules
Browse files Browse the repository at this point in the history
  • Loading branch information
mdjermanovic committed Nov 8, 2024
1 parent 328f317 commit 17ca5dd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/package/exports.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,12 @@ describe("Package exports", () => {
it("has all available rules exported in the ESLint plugin", async () => {
const allRules = (await fs.readdir(rulesDir))
.filter(name => name.endsWith(".js"))
.map(name => name.slice(0, -".js".length));
.map(name => name.slice(0, -".js".length))
.sort();
const exportedRules = exports.default.rules;

assert.deepStrictEqual(
Object.keys(exportedRules),
Object.keys(exportedRules).sort(),
allRules,
"Expected all rules to be exported in the ESLint plugin (`plugin.rules` in `src/index.js`)",
);
Expand Down

0 comments on commit 17ca5dd

Please sign in to comment.