Skip to content

Commit 0b4f89c

Browse files
committed
fix: update test to match new export behavior without rules-{slug} prefix
1 parent 48f7b44 commit 0b4f89c

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/core/config/__tests__/CustomModesManager.spec.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1744,10 +1744,13 @@ describe("CustomModesManager", () => {
17441744
expect(rulesFiles).toBeDefined()
17451745
expect(rulesFiles.length).toBe(2)
17461746

1747-
// Check that all paths use forward slashes
1747+
// Check that all paths use forward slashes and do NOT include the rules-{slug} prefix
17481748
rulesFiles.forEach((file: any) => {
17491749
expect(file.relativePath).not.toContain("\\")
1750-
expect(file.relativePath).toMatch(/^rules-test-mode\//)
1750+
// The PR excludes the rules-{slug} folder from paths
1751+
expect(file.relativePath).not.toMatch(/^rules-test-mode\//)
1752+
// Files should be at the root level now
1753+
expect(file.relativePath).toMatch(/^rule\d+\.md$/)
17511754
})
17521755

17531756
// Ensure no backslashes in the entire exported YAML

0 commit comments

Comments
 (0)