Adjust consumers of playwright-common

This commit is contained in:
Michael Telatynski 2026-04-09 15:22:56 +01:00
parent 03e12cbd22
commit 540e620f40
No known key found for this signature in database
GPG Key ID: A2B008A5F49F5D0D
8 changed files with 89 additions and 65 deletions

View File

@ -30,9 +30,9 @@
"lint:types": "nx lint:types",
"lint:style": "stylelint \"res/css/**/*.pcss\"",
"test": "nx test:unit",
"test:playwright": "playwright test",
"test:playwright:open": "pnpm test:playwright --ui",
"test:playwright:screenshots": "playwright-screenshots-experimental pnpm playwright test --update-snapshots --project=Chrome --grep @screenshot",
"test:playwright": "nx test:playwright",
"test:playwright:open": "nx test:playwright --ui",
"test:playwright:screenshots": "nx test:playwright:screenshots",
"coverage": "pnpm test --coverage",
"analyse:webpack-bundles": "webpack-bundle-analyzer webpack-stats.json webapp"
},
@ -127,8 +127,7 @@
"@babel/preset-typescript": "^7.12.7",
"@casualbot/jest-sonar-reporter": "2.5.0",
"@element-hq/element-call-embedded": "0.18.0",
"@element-hq/element-web-playwright-common": "catalog:",
"@element-hq/element-web-playwright-common-local": "workspace:*",
"@element-hq/element-web-playwright-common": "workspace:*",
"@fetch-mock/jest": "^0.2.20",
"@jest/globals": "^30.2.0",
"@peculiar/webcrypto": "^1.4.3",

View File

@ -53,6 +53,16 @@
"cwd": "apps/web"
},
"dependsOn": ["^build"]
},
"test:playwright": {
"command": "playwright test",
"options": { "cwd": "apps/web" },
"dependsOn": ["^build:playwright"]
},
"test:playwright:screenshots": {
"command": "playwright-screenshots nx test:playwright --update-snapshots --project=Chrome --grep @screenshot",
"options": { "cwd": "apps/web" },
"dependsOn": ["^build:playwright"]
}
}
}

View File

@ -27,7 +27,7 @@
"devDependencies": {
"@action-validator/cli": "^0.6.0",
"@action-validator/core": "^0.6.0",
"@element-hq/element-web-playwright-common": "catalog:",
"@element-hq/element-web-playwright-common": "workspace:*",
"@nx-tools/nx-container": "^7.2.1",
"@nx/jest": "^22.5.0",
"@playwright/test": "catalog:",

View File

@ -3,6 +3,13 @@
"projectType": "library",
"root": "packages/playwright-common",
"targets": {
"build:playwright": {
"cache": true,
"command": "tsc",
"inputs": ["src"],
"outputs": ["{projectRoot}/lib"],
"options": { "cwd": "packages/playwright-common" }
},
"docker:prebuild": {
"cache": true,
"command": "echo PLAYWRIGHT_VERSION=$(pnpm --silent -- playwright --version | awk '{print $2}') > .env.docker:build",

View File

@ -69,7 +69,7 @@
"temporal-polyfill": "^0.3.0"
},
"devDependencies": {
"@element-hq/element-web-playwright-common-local": "workspace:*",
"@element-hq/element-web-playwright-common": "workspace:*",
"@fetch-mock/vitest": "^0.2.18",
"@fontsource/inter": "catalog:",
"@matrix-org/react-sdk-module-api": "^2.5.0",

View File

@ -40,17 +40,17 @@
"test:storybook": {
"command": "vitest --project=storybook",
"options": { "cwd": "packages/shared-components" },
"dependsOn": ["typedoc"]
"dependsOn": ["typedoc", "^build:playwright"]
},
"test:storybook:update": {
"command": "playwright-screenshots-experimental nx test:storybook --run --update",
"command": "playwright-screenshots nx test:storybook --run --update",
"options": {
"env": {
"CI": "1"
},
"cwd": "packages/shared-components"
},
"dependsOn": ["typedoc"]
"dependsOn": ["typedoc", "^build:playwright"]
}
}
}

117
pnpm-lock.yaml generated
View File

@ -9,9 +9,6 @@ catalogs:
'@element-hq/element-web-module-api':
specifier: 1.12.0
version: 1.12.0
'@element-hq/element-web-playwright-common':
specifier: 2.4.0
version: 2.4.0
'@fontsource/inter':
specifier: 5.2.8
version: 5.2.8
@ -139,8 +136,8 @@ importers:
specifier: ^0.6.0
version: 0.6.0
'@element-hq/element-web-playwright-common':
specifier: 'catalog:'
version: 2.4.0(@element-hq/element-web-module-api@1.12.0(@matrix-org/react-sdk-module-api@2.5.0(patch_hash=016146c9cc96e6363609d2b2ac0896ccef567882eb1d73b75a77b8a30929de96)(react@19.2.4))(@types/react-dom@19.2.3(@types/react@19.2.10))(@types/react@19.2.10)(matrix-web-i18n@3.6.0)(react@19.2.4))(@playwright/test@1.59.1)(playwright-core@1.59.1)
specifier: workspace:*
version: link:packages/playwright-common
'@nx-tools/nx-container':
specifier: ^7.2.1
version: 7.2.1(@nx/devkit@22.5.3(nx@22.5.4))(@nx/js@22.5.3(@babel/traverse@7.29.0)(nx@22.5.4))(dotenv@17.4.0)(nx@22.5.4)(tslib@2.8.1)
@ -188,10 +185,10 @@ importers:
version: 5.9.3
vitepress:
specifier: ^1.6.4
version: 1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(react@19.2.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3)
version: 1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3)
vitepress-plugin-mermaid:
specifier: ^2.0.17
version: 2.0.17(mermaid@11.14.0)(vitepress@1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(react@19.2.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3))
version: 2.0.17(mermaid@11.14.0)(vitepress@1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3))
yaml:
specifier: 2.8.3
version: 2.8.3
@ -465,7 +462,7 @@ importers:
version: 1.0.3
matrix-js-sdk:
specifier: github:matrix-org/matrix-js-sdk#develop
version: https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/6371e4b25206dcd459d19375f5d046993ce11b1b
version: https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/f17f013f1e0d68622e9dd2f863689b7cd0ae09d1
matrix-widget-api:
specifier: ^1.17.0
version: 1.17.0
@ -597,9 +594,6 @@ importers:
specifier: 0.18.0
version: 0.18.0
'@element-hq/element-web-playwright-common':
specifier: 'catalog:'
version: 2.4.0(@element-hq/element-web-module-api@1.12.0(@matrix-org/react-sdk-module-api@2.5.0(patch_hash=016146c9cc96e6363609d2b2ac0896ccef567882eb1d73b75a77b8a30929de96)(react@19.2.4))(@types/react-dom@19.2.3(@types/react@19.2.10))(@types/react@19.2.10)(matrix-web-i18n@3.6.0)(react@19.2.4))(@playwright/test@1.59.1)(playwright-core@1.59.1)
'@element-hq/element-web-playwright-common-local':
specifier: workspace:*
version: link:../../packages/playwright-common
'@fetch-mock/jest':
@ -928,7 +922,47 @@ importers:
version: 2.8.3
packages/playwright-common:
dependencies:
'@axe-core/playwright':
specifier: ^4.10.1
version: 4.11.1(playwright-core@1.59.1)
'@playwright/test':
specifier: 'catalog:'
version: 1.59.1
'@testcontainers/postgresql':
specifier: ^11.0.0
version: 11.11.0
glob:
specifier: ^13.0.5
version: 13.0.6
lodash-es:
specifier: ^4.17.23
version: 4.18.1
mailpit-api:
specifier: ^1.2.0
version: 1.7.0
playwright-core:
specifier: 'catalog:'
version: 1.59.1
strip-ansi:
specifier: ^7.1.0
version: 7.2.0
testcontainers:
specifier: ^11.0.0
version: 11.12.0
yaml:
specifier: 2.8.3
version: 2.8.3
devDependencies:
'@element-hq/element-web-module-api':
specifier: '*'
version: 1.12.0(@matrix-org/react-sdk-module-api@2.5.0(patch_hash=016146c9cc96e6363609d2b2ac0896ccef567882eb1d73b75a77b8a30929de96)(react@19.2.4))(@types/react-dom@19.2.3(@types/react@19.2.10))(@types/react@19.2.10)(matrix-web-i18n@3.6.0)(react@19.2.4)
'@types/lodash-es':
specifier: ^4.17.12
version: 4.17.12
typescript:
specifier: ^5.8.2
version: 5.9.3
wait-on:
specifier: ^9.0.4
version: 9.0.4
@ -984,7 +1018,7 @@ importers:
specifier: ^0.3.0
version: 0.3.2
devDependencies:
'@element-hq/element-web-playwright-common-local':
'@element-hq/element-web-playwright-common':
specifier: workspace:*
version: link:../playwright-common
'@fetch-mock/vitest':
@ -2410,15 +2444,6 @@ packages:
matrix-web-i18n:
optional: true
'@element-hq/element-web-playwright-common@2.4.0':
resolution: {integrity: sha512-6zXRkeTlCEEBfUKgE42+5+RYGQloQB4p/HBdTBxjnMArAnZY/+8GE8pY1CeoJrmRISxGdDbdWkMEyT7bwIBx/g==}
engines: {node: '>=20.0.0'}
hasBin: true
peerDependencies:
'@element-hq/element-web-module-api': '*'
'@playwright/test': ^1.52.0
playwright-core: ^1.52.0
'@emnapi/core@1.8.1':
resolution: {integrity: sha512-AvT9QFpxK0Zd8J0jopedNm+w/2fIzvtPKPjqyw9jwvBaReTTqPBk9Hixaz7KbjimP+QNz605/XnjFcDAL2pqBg==}
@ -5405,6 +5430,9 @@ packages:
'@types/linkify-it@5.0.0':
resolution: {integrity: sha512-sVDA58zAw4eWAffKOaQH5/5j3XeayukzDk+ewSsnv3p4yJEZHCCzMDiZM8e0OUrRvmpGZ85jf4yDHkHsgBNr9Q==}
'@types/lodash-es@4.17.12':
resolution: {integrity: sha512-0NgftHUcV4v34VhXm8QBSftKVXtbkBG3ViCjs6+eJ5a6y6Mi/jiFGPc1sC7QK+9BFhWrURE3EOggmWaSxL9OzQ==}
'@types/lodash@4.17.24':
resolution: {integrity: sha512-gIW7lQLZbue7lRSWEFql49QJJWThrTFFeIMJdp3eH4tKoxm1OvEPg02rm4wCCSHS0cL3/Fizimb35b7k8atwsQ==}
@ -9845,8 +9873,8 @@ packages:
matrix-events-sdk@0.0.1:
resolution: {integrity: sha512-1QEOsXO+bhyCroIe2/A5OwaxHvBm7EsSQ46DEDn8RBIfQwN5HWBpFvyWWR4QY0KHPPnnJdI99wgRiAl7Ad5qaA==}
matrix-js-sdk@https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/6371e4b25206dcd459d19375f5d046993ce11b1b:
resolution: {tarball: https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/6371e4b25206dcd459d19375f5d046993ce11b1b}
matrix-js-sdk@https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/f17f013f1e0d68622e9dd2f863689b7cd0ae09d1:
resolution: {tarball: https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/f17f013f1e0d68622e9dd2f863689b7cd0ae09d1}
version: 41.3.0
engines: {node: '>=22.0.0'}
@ -14774,9 +14802,9 @@ snapshots:
'@docsearch/css@3.8.2': {}
'@docsearch/js@3.8.2(@algolia/client-search@5.50.0)(@types/react@19.2.10)(react@19.2.4)(search-insights@2.17.3)':
'@docsearch/js@3.8.2(@algolia/client-search@5.50.0)(@types/react@19.2.10)(search-insights@2.17.3)':
dependencies:
'@docsearch/react': 3.8.2(@algolia/client-search@5.50.0)(@types/react@19.2.10)(react@19.2.4)(search-insights@2.17.3)
'@docsearch/react': 3.8.2(@algolia/client-search@5.50.0)(@types/react@19.2.10)(search-insights@2.17.3)
preact: 10.28.3
transitivePeerDependencies:
- '@algolia/client-search'
@ -14785,7 +14813,7 @@ snapshots:
- react-dom
- search-insights
'@docsearch/react@3.8.2(@algolia/client-search@5.50.0)(@types/react@19.2.10)(react@19.2.4)(search-insights@2.17.3)':
'@docsearch/react@3.8.2(@algolia/client-search@5.50.0)(@types/react@19.2.10)(search-insights@2.17.3)':
dependencies:
'@algolia/autocomplete-core': 1.17.7(@algolia/client-search@5.50.0)(algoliasearch@5.50.0)(search-insights@2.17.3)
'@algolia/autocomplete-preset-algolia': 1.17.7(@algolia/client-search@5.50.0)(algoliasearch@5.50.0)
@ -14793,7 +14821,6 @@ snapshots:
algoliasearch: 5.50.0
optionalDependencies:
'@types/react': 19.2.10
react: 19.2.4
search-insights: 2.17.3
transitivePeerDependencies:
- '@algolia/client-search'
@ -14916,28 +14943,6 @@ snapshots:
'@matrix-org/react-sdk-module-api': 2.5.0(patch_hash=016146c9cc96e6363609d2b2ac0896ccef567882eb1d73b75a77b8a30929de96)(react@19.2.4)
matrix-web-i18n: 3.6.0
'@element-hq/element-web-playwright-common@2.4.0(@element-hq/element-web-module-api@1.12.0(@matrix-org/react-sdk-module-api@2.5.0(patch_hash=016146c9cc96e6363609d2b2ac0896ccef567882eb1d73b75a77b8a30929de96)(react@19.2.4))(@types/react-dom@19.2.3(@types/react@19.2.10))(@types/react@19.2.10)(matrix-web-i18n@3.6.0)(react@19.2.4))(@playwright/test@1.59.1)(playwright-core@1.59.1)':
dependencies:
'@axe-core/playwright': 4.11.1(playwright-core@1.59.1)
'@element-hq/element-web-module-api': 1.12.0(@matrix-org/react-sdk-module-api@2.5.0(patch_hash=016146c9cc96e6363609d2b2ac0896ccef567882eb1d73b75a77b8a30929de96)(react@19.2.4))(@types/react-dom@19.2.3(@types/react@19.2.10))(@types/react@19.2.10)(matrix-web-i18n@3.6.0)(react@19.2.4)
'@playwright/test': 1.59.1
'@testcontainers/postgresql': 11.11.0
glob: 13.0.6
lodash-es: 4.18.1
mailpit-api: 1.7.0
playwright-core: 1.59.1
strip-ansi: 7.2.0
testcontainers: 11.12.0
yaml: 2.8.3
transitivePeerDependencies:
- bare-abort-controller
- bare-buffer
- bufferutil
- debug
- react-native-b4a
- supports-color
- utf-8-validate
'@emnapi/core@1.8.1':
dependencies:
'@emnapi/wasi-threads': 1.1.0
@ -18158,6 +18163,10 @@ snapshots:
'@types/linkify-it@5.0.0': {}
'@types/lodash-es@4.17.12':
dependencies:
'@types/lodash': 4.17.24
'@types/lodash@4.17.24': {}
'@types/markdown-it@14.1.2':
@ -23464,7 +23473,7 @@ snapshots:
matrix-events-sdk@0.0.1: {}
matrix-js-sdk@https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/6371e4b25206dcd459d19375f5d046993ce11b1b:
matrix-js-sdk@https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/f17f013f1e0d68622e9dd2f863689b7cd0ae09d1:
dependencies:
'@babel/runtime': 7.28.6
'@matrix-org/matrix-sdk-crypto-wasm': 18.0.0
@ -27112,17 +27121,17 @@ snapshots:
- '@emnapi/core'
- '@emnapi/runtime'
vitepress-plugin-mermaid@2.0.17(mermaid@11.14.0)(vitepress@1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(react@19.2.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3)):
vitepress-plugin-mermaid@2.0.17(mermaid@11.14.0)(vitepress@1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3)):
dependencies:
mermaid: 11.14.0
vitepress: 1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(react@19.2.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3)
vitepress: 1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3)
optionalDependencies:
'@mermaid-js/mermaid-mindmap': 9.3.0
vitepress@1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(react@19.2.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3):
vitepress@1.6.4(@algolia/client-search@5.50.0)(@types/node@18.19.130)(@types/react@19.2.10)(axios@1.13.5)(jwt-decode@4.0.0)(lightningcss@1.32.0)(postcss@8.5.8)(qrcode@1.5.4)(search-insights@2.17.3)(sugarss@5.0.1(postcss@8.5.8))(terser@5.46.1)(typescript@5.9.3):
dependencies:
'@docsearch/css': 3.8.2
'@docsearch/js': 3.8.2(@algolia/client-search@5.50.0)(@types/react@19.2.10)(react@19.2.4)(search-insights@2.17.3)
'@docsearch/js': 3.8.2(@algolia/client-search@5.50.0)(@types/react@19.2.10)(search-insights@2.17.3)
'@iconify-json/simple-icons': 1.2.75
'@shikijs/core': 2.5.0
'@shikijs/transformers': 2.5.0

View File

@ -13,7 +13,6 @@ catalog:
"@types/react": ^19.2.10
"@types/react-dom": ^19.2.3
# playwright
"@element-hq/element-web-playwright-common": 2.4.0
"@playwright/test": 1.59.1
"playwright-core": 1.59.1
# Module API