Skip to content

Commit 7ba6647

Browse files
refactor(e2e): use inline oxlint disable for application-provider locators
Replace file-level no-raw-locators override with a scoped block comment next to the nested div card selectors, matching repo convention. Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent ee1d77c commit 7ba6647

2 files changed

Lines changed: 2 additions & 8 deletions

File tree

e2e-tests/oxlint.config.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -68,14 +68,6 @@ export default defineConfig({
6868
],
6969
},
7070
overrides: [
71-
{
72-
// Application-provider cards are nested divs inside one article; role-based
73-
// locators alone match multiple counters/buttons (strict mode failures in CI).
74-
files: ["playwright/e2e/plugins/application-provider.spec.ts"],
75-
rules: {
76-
"playwright/no-raw-locators": "off",
77-
},
78-
},
7971
{
8072
files: ["playwright/e2e/auth-providers/**/*.spec.ts"],
8173
rules: {

e2e-tests/playwright/e2e/plugins/application-provider.spec.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ test.describe("Test ApplicationProvider", () => {
3131
await uiHelper.verifyTextinCard("Context one", "Context one");
3232

3333
// Find card containers within main article that contain "Context one"
34+
/* oxlint-disable playwright/no-raw-locators -- per-card containers are nested divs inside one article */
3435
const contextOneCards = page
3536
.getByRole("main")
3637
.getByRole("article")
@@ -57,6 +58,7 @@ test.describe("Test ApplicationProvider", () => {
5758
.getByRole("article")
5859
.locator("> div > div")
5960
.filter({ hasText: "Context two" });
61+
/* oxlint-enable playwright/no-raw-locators */
6062

6163
// Click increment on the first Context two card
6264
await contextTwoCards.first().getByRole("button", { name: "+" }).click();

0 commit comments

Comments
 (0)