0
0
mirror of https://github.com/go-gitea/gitea.git synced 2026-03-05 16:53:03 +01:00

Add playwright/no-raw-locators eslint rule for e2e tests

Forbid page.locator() in favor of semantic locators like getByRole,
getByLabel, getByText.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
silverwind 2026-02-15 11:43:32 +01:00
parent cbe336f466
commit 3dd69ecfc0
No known key found for this signature in database
GPG Key ID: 2E62B41C93869443

View File

@ -913,6 +913,7 @@ export default defineConfig([
files: ['tests/e2e/*.test.ts'],
rules: {
...playwright.configs['flat/recommended'].rules,
'playwright/no-raw-locators': [2],
},
},
{