@public-ui/visual-tests 2.1.2 → 2.1.4-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@public-ui/visual-tests",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.4-alpha.1",
|
|
4
4
|
"license": "EUPL-1.2",
|
|
5
5
|
"homepage": "https://public-ui.github.io",
|
|
6
6
|
"repository": {
|
|
@@ -22,20 +22,20 @@
|
|
|
22
22
|
"kolibri-visual-test": "src/index.js"
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@playwright/test": "1.
|
|
25
|
+
"@playwright/test": "1.45.0",
|
|
26
26
|
"axe-playwright": "2.0.1",
|
|
27
27
|
"portfinder": "1.0.32",
|
|
28
28
|
"serve": "14.2.3",
|
|
29
|
-
"@public-ui/sample-react": "2.1.
|
|
29
|
+
"@public-ui/sample-react": "2.1.4-alpha.1"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@babel/eslint-parser": "7.24.7",
|
|
33
33
|
"@babel/plugin-syntax-import-attributes": "7.24.7",
|
|
34
34
|
"@babel/preset-env": "7.24.7",
|
|
35
35
|
"eslint": "8.57.0",
|
|
36
|
-
"eslint-plugin-no-loops": "0.
|
|
37
|
-
"knip": "5.
|
|
38
|
-
"prettier": "3.3.
|
|
36
|
+
"eslint-plugin-no-loops": "0.4.0",
|
|
37
|
+
"knip": "5.23.0",
|
|
38
|
+
"prettier": "3.3.2"
|
|
39
39
|
},
|
|
40
40
|
"files": [
|
|
41
41
|
"playwright.config.js",
|
|
@@ -140,6 +140,30 @@ ROUTES.set('details/basic', {
|
|
|
140
140
|
skipFailures: false,
|
|
141
141
|
},
|
|
142
142
|
});
|
|
143
|
+
ROUTES.set('drawer/basic?align=left', {
|
|
144
|
+
viewportSize: {
|
|
145
|
+
width: 1920,
|
|
146
|
+
height: 600,
|
|
147
|
+
},
|
|
148
|
+
});
|
|
149
|
+
ROUTES.set('drawer/basic?align=top', {
|
|
150
|
+
viewportSize: {
|
|
151
|
+
width: 800,
|
|
152
|
+
height: 600,
|
|
153
|
+
},
|
|
154
|
+
});
|
|
155
|
+
ROUTES.set('drawer/basic?align=right', {
|
|
156
|
+
viewportSize: {
|
|
157
|
+
width: 1920,
|
|
158
|
+
height: 600,
|
|
159
|
+
},
|
|
160
|
+
});
|
|
161
|
+
ROUTES.set('drawer/basic?align=bottom', {
|
|
162
|
+
viewportSize: {
|
|
163
|
+
width: 800,
|
|
164
|
+
height: 600,
|
|
165
|
+
},
|
|
166
|
+
});
|
|
143
167
|
ROUTES.set('form/basic', {
|
|
144
168
|
axe: {
|
|
145
169
|
skipFailures: false,
|
|
@@ -426,3 +450,25 @@ ROUTES.set('scenarios/disabled-interactive-scenario', {
|
|
|
426
450
|
skipFailures: false,
|
|
427
451
|
},
|
|
428
452
|
});
|
|
453
|
+
|
|
454
|
+
/* Focus tests */
|
|
455
|
+
ROUTES.set('scenarios/focus-elements?component=inputCheckbox');
|
|
456
|
+
ROUTES.set('scenarios/focus-elements?component=inputColor');
|
|
457
|
+
ROUTES.set('scenarios/focus-elements?component=inputDate');
|
|
458
|
+
ROUTES.set('scenarios/focus-elements?component=inputEmail');
|
|
459
|
+
ROUTES.set('scenarios/focus-elements?component=inputFile');
|
|
460
|
+
ROUTES.set('scenarios/focus-elements?component=inputFileMultiple');
|
|
461
|
+
ROUTES.set('scenarios/focus-elements?component=inputNumber');
|
|
462
|
+
ROUTES.set('scenarios/focus-elements?component=inputPassword');
|
|
463
|
+
ROUTES.set('scenarios/focus-elements?component=inputRadio');
|
|
464
|
+
ROUTES.set('scenarios/focus-elements?component=inputRange');
|
|
465
|
+
ROUTES.set('scenarios/focus-elements?component=inputText');
|
|
466
|
+
ROUTES.set('scenarios/focus-elements?component=select');
|
|
467
|
+
ROUTES.set('scenarios/focus-elements?component=selectMultiple');
|
|
468
|
+
ROUTES.set('scenarios/focus-elements?component=textarea');
|
|
469
|
+
ROUTES.set('scenarios/focus-elements?component=accordion');
|
|
470
|
+
ROUTES.set('scenarios/focus-elements?component=button');
|
|
471
|
+
ROUTES.set('scenarios/focus-elements?component=buttonLink');
|
|
472
|
+
ROUTES.set('scenarios/focus-elements?component=details');
|
|
473
|
+
ROUTES.set('scenarios/focus-elements?component=link');
|
|
474
|
+
ROUTES.set('scenarios/focus-elements?component=linkButton');
|
|
@@ -51,7 +51,8 @@ ROUTES.forEach((options, route) => {
|
|
|
51
51
|
return;
|
|
52
52
|
}
|
|
53
53
|
test(`snapshot for ${route}`, async ({ page }) => {
|
|
54
|
-
|
|
54
|
+
const hideMenusParam = `${route.includes('?') ? '&' : '?'}hideMenus`;
|
|
55
|
+
await page.goto(`/#${route}${hideMenusParam}`, { waitUntil: 'networkidle' });
|
|
55
56
|
if (options?.viewportSize) {
|
|
56
57
|
await page.setViewportSize(options.viewportSize);
|
|
57
58
|
}
|