@applitools/eyes-playwright 1.13.0 → 1.13.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/CHANGELOG.md +8 -0
- package/README.md +56 -38
- package/dist/api.js +6 -3
- package/package.json +7 -7
- package/types/api.d.ts +10 -7
package/CHANGELOG.md
CHANGED
|
@@ -11,6 +11,14 @@
|
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
14
|
+
## 1.13.1 - 2023/1/17
|
|
15
|
+
|
|
16
|
+
### Features
|
|
17
|
+
### Bug fixes
|
|
18
|
+
- Handle fake shadowRoot with UFG
|
|
19
|
+
- Handed error during polling in long requests to eyes server
|
|
20
|
+
- Additional internal event logs
|
|
21
|
+
|
|
14
22
|
## 1.13.0 - 2022/11/29
|
|
15
23
|
|
|
16
24
|
### Features
|
package/README.md
CHANGED
|
@@ -7,52 +7,55 @@
|
|
|
7
7
|
</div>
|
|
8
8
|
<br/>
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
### Table of contents
|
|
11
11
|
|
|
12
12
|
- [Installation](#installation)
|
|
13
13
|
- [Applitools API key](#applitools-api-key)
|
|
14
14
|
- [Usage](#usage)
|
|
15
15
|
- [Getting started with the API](#getting-started-with-the-api)
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
- [
|
|
23
|
-
- [
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
16
|
+
- [Eyes constructor](#eyes-constructor)
|
|
17
|
+
- [open](#open)
|
|
18
|
+
- [Visual tests and baselines](#visual-tests-and-baselines)
|
|
19
|
+
- [Batches](#batches)
|
|
20
|
+
- [check](#check)
|
|
21
|
+
- [`checkSettings`](#checksettings)
|
|
22
|
+
- [Page screenshot](#page-screenshot)
|
|
23
|
+
- [Region screenshot](#region-screenshot)
|
|
24
|
+
- [Working with frames](#working-with-frames)
|
|
25
|
+
- [Ignore Regions](#ignore-regions)
|
|
26
|
+
- [Floating Regions](#floating-regions)
|
|
27
|
+
- [Content/Strict/Layout Regions](#contentstrictlayout-regions)
|
|
28
|
+
- [Accessiblity Regions](#accessiblity-regions)
|
|
29
|
+
- [Scroll root element](#scroll-root-element)
|
|
30
|
+
- [Tag (`withName`)](#tag-withname)
|
|
31
|
+
- [Lazy loading (`lazyLoad`)](#lazy-loading-lazyload)
|
|
32
|
+
- [Other checkSettings configuration](#other-checksettings-configuration)
|
|
33
|
+
- [close](#close)
|
|
34
34
|
- [Runners](#runners)
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
35
|
+
- [Purpose of runners](#purpose-of-runners)
|
|
36
|
+
- [1. Use the Ultrafast grid](#1-use-the-ultrafast-grid)
|
|
37
|
+
- [2. Manage tests across multiple `Eyes` instances](#2-manage-tests-across-multiple-eyes-instances)
|
|
38
38
|
- [Recipes for common tasks](#recipes-for-common-tasks)
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
39
|
+
- [Configure Server URL](#configure-server-url)
|
|
40
|
+
- [Configure Proxy](#configure-proxy)
|
|
41
|
+
- [Make every visual test correspond to a functional test](#make-every-visual-test-correspond-to-a-functional-test)
|
|
42
|
+
- [Organize tests in batches](#organize-tests-in-batches)
|
|
43
|
+
- [Method 1: environment variable](#method-1-environment-variable)
|
|
44
|
+
- [Method 2: `eyes.setBatch`](#method-2-eyessetbatch)
|
|
45
|
+
- [Stitch mode](#stitch-mode)
|
|
46
|
+
- [Background information](#background-information)
|
|
47
47
|
- [1. Stitch mode: Scroll](#1-stitch-mode-scroll)
|
|
48
48
|
- [2. Stitch mode: CSS](#2-stitch-mode-css)
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
49
|
+
- [Stitch overlap](#stitch-overlap)
|
|
50
|
+
- [Match level](#match-level)
|
|
51
|
+
- [Ignore displacements](#ignore-displacements)
|
|
52
|
+
- [Test properties](#test-properties)
|
|
53
|
+
- [Test results](#test-results)
|
|
54
|
+
- [Logging](#logging)
|
|
55
|
+
- [Configuring browsers for the Ultrafast grid](#configuring-browsers-for-the-ultrafast-grid)
|
|
56
|
+
- [Desktop browsers](#desktop-browsers)
|
|
57
|
+
- [Chrome device emulation](#chrome-device-emulation)
|
|
58
|
+
- [iOS device](#ios-device)
|
|
56
59
|
|
|
57
60
|
|
|
58
61
|
## Installation
|
|
@@ -716,7 +719,7 @@ It's possible to provide additional information about each test in custom fields
|
|
|
716
719
|
This is done by calling `setProperties` on the configuration, and providing it with an array of properties with the structure `{name, value}`. For example:
|
|
717
720
|
|
|
718
721
|
```js
|
|
719
|
-
const {Eyes
|
|
722
|
+
const {Eyes} = require('@applitools/eyes-playwright')
|
|
720
723
|
|
|
721
724
|
const eyes = new Eyes()
|
|
722
725
|
|
|
@@ -725,6 +728,21 @@ configuration.setProperties([{name: 'my custom property', value: 'some value'}])
|
|
|
725
728
|
eyes.setConfiguration(configuration)
|
|
726
729
|
```
|
|
727
730
|
|
|
731
|
+
The test properties could also be specified per batch by calling `setProperties` on the batch info, and providing it with an array of properties with the structure `{name, value}`. For example:
|
|
732
|
+
|
|
733
|
+
```js
|
|
734
|
+
const {Eyes, BatchInfo} = require('@applitools/eyes-playwright')
|
|
735
|
+
|
|
736
|
+
const eyes = new Eyes()
|
|
737
|
+
|
|
738
|
+
const batch = new BatchInfo()
|
|
739
|
+
batch.setProperties([{name: 'my custom batch property', value: 'some value'}])
|
|
740
|
+
|
|
741
|
+
const configuration = eyes.getConfiguration()
|
|
742
|
+
configuration.setBatch(batch)
|
|
743
|
+
eyes.setConfiguration(configuration)
|
|
744
|
+
```
|
|
745
|
+
|
|
728
746
|
### Test results
|
|
729
747
|
|
|
730
748
|
The results of the test can be consumed as the return value from `eyes.close`. Here's an example for creating a formatted output string out of the `TestResults` object:
|
package/dist/api.js
CHANGED
|
@@ -26,7 +26,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
26
26
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
exports.closeBatch = exports.BatchClose = exports.Target = exports.CheckSettings = exports.Configuration = exports.Eyes = void 0;
|
|
29
|
+
exports.closeBatch = exports.BatchClose = exports.Target = exports.CheckSettings = exports.CheckSettingsAutomation = exports.Configuration = exports.Eyes = void 0;
|
|
30
30
|
const core_1 = require("@applitools/core");
|
|
31
31
|
const api = __importStar(require("@applitools/eyes-api"));
|
|
32
32
|
const spec = __importStar(require("@applitools/spec-driver-playwright"));
|
|
@@ -43,10 +43,13 @@ class Configuration extends api.Configuration {
|
|
|
43
43
|
}
|
|
44
44
|
exports.Configuration = Configuration;
|
|
45
45
|
Configuration._spec = sdk;
|
|
46
|
-
class
|
|
46
|
+
class CheckSettingsAutomation extends api.CheckSettingsAutomation {
|
|
47
|
+
}
|
|
48
|
+
exports.CheckSettingsAutomation = CheckSettingsAutomation;
|
|
49
|
+
CheckSettingsAutomation._spec = sdk;
|
|
50
|
+
class CheckSettings extends CheckSettingsAutomation {
|
|
47
51
|
}
|
|
48
52
|
exports.CheckSettings = CheckSettings;
|
|
49
|
-
CheckSettings._spec = sdk;
|
|
50
53
|
exports.Target = { ...api.Target, spec: sdk };
|
|
51
54
|
class BatchClose extends api.BatchClose {
|
|
52
55
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applitools/eyes-playwright",
|
|
3
|
-
"version": "1.13.
|
|
3
|
+
"version": "1.13.1",
|
|
4
4
|
"description": "Applitools Eyes SDK for Playwright",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eyes-playwright",
|
|
@@ -58,17 +58,17 @@
|
|
|
58
58
|
}
|
|
59
59
|
},
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"@applitools/core": "1.
|
|
62
|
-
"@applitools/eyes-api": "1.
|
|
63
|
-
"@applitools/spec-driver-playwright": "1.3.
|
|
61
|
+
"@applitools/core": "1.4.0",
|
|
62
|
+
"@applitools/eyes-api": "1.12.0",
|
|
63
|
+
"@applitools/spec-driver-playwright": "1.3.7"
|
|
64
64
|
},
|
|
65
65
|
"devDependencies": {
|
|
66
66
|
"@applitools/api-extractor": "1.2.11",
|
|
67
|
-
"@applitools/bongo": "^2.2.
|
|
67
|
+
"@applitools/bongo": "^2.2.2",
|
|
68
68
|
"@applitools/scripts": "1.2.0",
|
|
69
|
-
"@applitools/sdk-coverage-tests": "2.7.
|
|
69
|
+
"@applitools/sdk-coverage-tests": "2.7.10",
|
|
70
70
|
"@applitools/sdk-shared": "0.9.15",
|
|
71
|
-
"@applitools/test-utils": "1.5.
|
|
71
|
+
"@applitools/test-utils": "1.5.8",
|
|
72
72
|
"@types/mocha": "^9.1.1",
|
|
73
73
|
"@types/node": "12",
|
|
74
74
|
"@typescript-eslint/eslint-plugin": "^5.27.0",
|
package/types/api.d.ts
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import type { Driver, Element, Selector } from '@applitools/spec-driver-playwright';
|
|
2
2
|
import * as api from '@applitools/eyes-api';
|
|
3
|
+
import * as spec from '@applitools/spec-driver-playwright';
|
|
3
4
|
export * from '@applitools/eyes-api';
|
|
4
5
|
export { Driver, Element, Selector };
|
|
5
6
|
export declare class Eyes extends api.Eyes<Driver, Element, Selector> {
|
|
6
|
-
protected static readonly _spec: import("@applitools/core").Core<Driver, Element | Selector, (string & {
|
|
7
|
+
protected static readonly _spec: import("@applitools/core").Core<Driver, spec.Context, Element<Node> | Selector, (string & {
|
|
7
8
|
__applitoolsBrand?: never;
|
|
8
9
|
}) | (import("playwright-core").Locator & {
|
|
9
10
|
__applitoolsBrand?: never;
|
|
@@ -12,24 +13,26 @@ export declare class Eyes extends api.Eyes<Driver, Element, Selector> {
|
|
|
12
13
|
}
|
|
13
14
|
export type ConfigurationPlain = api.ConfigurationPlain<Element, Selector>;
|
|
14
15
|
export declare class Configuration extends api.Configuration<Element, Selector> {
|
|
15
|
-
protected static readonly _spec: import("@applitools/core").Core<Driver, Element | Selector, (string & {
|
|
16
|
+
protected static readonly _spec: import("@applitools/core").Core<Driver, spec.Context, Element<Node> | Selector, (string & {
|
|
16
17
|
__applitoolsBrand?: never;
|
|
17
18
|
}) | (import("playwright-core").Locator & {
|
|
18
19
|
__applitoolsBrand?: never;
|
|
19
20
|
})>;
|
|
20
21
|
}
|
|
21
22
|
export type OCRRegion = api.OCRRegion<Element, Selector>;
|
|
22
|
-
export type
|
|
23
|
-
export declare class
|
|
24
|
-
protected static readonly _spec: import("@applitools/core").Core<Driver, Element | Selector, (string & {
|
|
23
|
+
export type CheckSettingsAutomationPlain = api.CheckSettingsAutomationPlain<Element, Selector>;
|
|
24
|
+
export declare class CheckSettingsAutomation extends api.CheckSettingsAutomation<Element, Selector> {
|
|
25
|
+
protected static readonly _spec: import("@applitools/core").Core<Driver, spec.Context, Element<Node> | Selector, (string & {
|
|
25
26
|
__applitoolsBrand?: never;
|
|
26
27
|
}) | (import("playwright-core").Locator & {
|
|
27
28
|
__applitoolsBrand?: never;
|
|
28
29
|
})>;
|
|
29
30
|
}
|
|
30
|
-
export declare
|
|
31
|
+
export declare class CheckSettings extends CheckSettingsAutomation {
|
|
32
|
+
}
|
|
33
|
+
export declare const Target: api.Target<Element<Node>, Selector>;
|
|
31
34
|
export declare class BatchClose extends api.BatchClose {
|
|
32
|
-
protected static readonly _spec: import("@applitools/core").Core<Driver, Element | Selector, (string & {
|
|
35
|
+
protected static readonly _spec: import("@applitools/core").Core<Driver, spec.Context, Element<Node> | Selector, (string & {
|
|
33
36
|
__applitoolsBrand?: never;
|
|
34
37
|
}) | (import("playwright-core").Locator & {
|
|
35
38
|
__applitoolsBrand?: never;
|