Skip to content

Commit

Permalink
chore(deps): update eslint-plugin-playwright to 2.x (#5355)
Browse files Browse the repository at this point in the history
* chore(deps): update eslint-plugin-playwright to 2.x

* chore: fix tsc check
  • Loading branch information
joshblack authored Dec 9, 2024
1 parent cf288b4 commit d57b1de
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 15 deletions.
10 changes: 8 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -200,8 +200,14 @@ module.exports = {
parserOptions: {
project: 'tsconfig.json',
},
extends: ['plugin:playwright/jest-playwright'],
rules: {},
extends: ['plugin:playwright/recommended'],
rules: {
'playwright/expect-expect': 'off',
'playwright/no-conditional-expect': 'off',
'playwright/no-conditional-in-test': 'off',
'playwright/no-wait-for-selector': 'off',
'playwright/valid-title': 'off',
},
},

// rules which apply only to Markdown
Expand Down
8 changes: 4 additions & 4 deletions e2e/components/DataTable.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -175,12 +175,12 @@ test.describe('DataTable', () => {
const region = page.getByRole('region')
const table = region.getByRole('table')

const tabIndex = await region.getAttribute('tabindex')
const labelledby = await region.getAttribute('aria-labelledby')
const tabIndex = region
const labelledby = region

await expect(region).toBeVisible()
expect(tabIndex).toBe('0')
expect(labelledby).toBe(headingId)
await expect(tabIndex).toHaveAttribute('tabindex', '0')
await expect(labelledby).toHaveAttribute('aria-labelledby', headingId!)

await expect(table).toBeVisible()
expect(labelledby).toBe(headingId)
Expand Down
50 changes: 42 additions & 8 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
"eslint-plugin-jest": "28.8.3",
"eslint-plugin-jsx-a11y": "6.7.1",
"eslint-plugin-mdx": "3.1.5",
"eslint-plugin-playwright": "0.15.1",
"eslint-plugin-playwright": "^2.1.0",
"eslint-plugin-prettier": "5.0.0",
"eslint-plugin-primer-react": "5.4.0",
"eslint-plugin-react": "7.32.2",
Expand Down

0 comments on commit d57b1de

Please sign in to comment.