@applitools/eyes-playwright 1.11.0 → 1.11.3

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.
Files changed (3) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/package.json +16 -16
  3. package/types/index.d.ts +187 -81
package/CHANGELOG.md CHANGED
@@ -4,6 +4,36 @@
4
4
 
5
5
 
6
6
 
7
+
8
+
9
+
10
+ ## 1.11.3 - 2022/5/2
11
+
12
+ ### Features
13
+ - Support UFG for native mobile
14
+ - `runner.getAllTestResults` returns the corresponding UFG browser/device configuration for each test. This is available as `runner.getAllTestResults()[i].browserInfo`.
15
+ ### Bug fixes
16
+ - `runner.getAllTestResults` now aborts unclosed tests
17
+ - `runner.getAllTestResults` now returns all results, including aborted tests
18
+ - `extractText` now supports regions that don't use hints while using `x`/`y` coordinates
19
+ - accept ios and android lowercase as driver platformName capability when using custom grid
20
+ - Fixed check region fully in classic execution when using CSS stitching
21
+ - Support data urls in iframes
22
+
23
+ ## 1.11.2 - 2022/1/13
24
+
25
+ - fix taking multiple dom snapshots with `layoutBreakpoints`
26
+ - updated to @applitools/eyes-sdk-core@12.24.13 (from 12.24.2)
27
+ - updated to @applitools/visual-grid-client@15.8.60 (from 15.8.47)
28
+
29
+ ## 1.11.1 - 2021/11/18
30
+
31
+ - updated to @applitools/eyes-sdk-core@12.24.1 (from 12.24.0)
32
+ - updated to @applitools/visual-grid-client@15.8.45 (from 15.8.44)
33
+ - updated to @applitools/eyes-sdk-core@12.24.2 (from 12.24.1)
34
+ - updated to @applitools/spec-driver-playwright@1.3.0 (from 1.2.0)
35
+ - updated to @applitools/visual-grid-client@15.8.47 (from 15.8.45)
36
+
7
37
  ## 1.11.0 - 2021/11/10
8
38
 
9
39
  - support cookies
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@applitools/eyes-playwright",
3
- "version": "1.11.0",
3
+ "version": "1.11.3",
4
4
  "description": "Applitools Eyes SDK for Playwright",
5
5
  "keywords": [
6
6
  "eyes-playwright",
@@ -41,15 +41,15 @@
41
41
  "scripts": {
42
42
  "lint": "eslint '**/*.ts'",
43
43
  "build": "ttsc",
44
- "generate:tests": "coverage-tests generate https://raw.githubusercontent.com/applitools/sdk.coverage.tests/master/js/config.js --name 'eyes-playwright'",
44
+ "generate:tests": "coverage-tests generate https://raw.githubusercontent.com/applitools/sdk.coverage.tests/universal-sdk/js/config.js --name 'eyes-playwright'",
45
45
  "test": "yarn test:coverage",
46
46
  "test:coverage": "yarn generate:tests && APPLITOOLS_BATCH_NAME='JS Coverage Tests: eyes-playwright' APPLITOOLS_BATCH_ID=$(uuidgen) XUNIT_FILE=coverage-test-report.xml mocha --config .mocharc.cvg.js",
47
47
  "report": "coverage-tests report https://raw.githubusercontent.com/applitools/sdk.coverage.tests/master/js/config.js --name 'eyes-playwright'",
48
48
  "deps": "bongo deps",
49
49
  "gh:test": "gh workflow run test.yml --ref $(git rev-parse --abbrev-ref HEAD) -f packages='playwright' -f links='types test-utils sdk-shared eyes-sdk-core visual-grid-client eyes-api spec-driver-playwright utils driver snippets screenshoter' -f linking-depth=3",
50
- "gh:publish": "gh workflow run publish.yml --ref $(git rev-parse --abbrev-ref HEAD) -f packages='playwright'",
51
- "preversion": "bongo preversion && yarn build",
52
- "version": "bongo version",
50
+ "gh:publish": "gh workflow run publish-playwright.yml --ref $(git rev-parse --abbrev-ref HEAD)",
51
+ "preversion": "bongo preversion --verifyPendingChanges && yarn build",
52
+ "version": "bongo version --withPendingChanges",
53
53
  "postversion": "bongo postversion"
54
54
  },
55
55
  "husky": {
@@ -58,18 +58,18 @@
58
58
  }
59
59
  },
60
60
  "dependencies": {
61
- "@applitools/eyes-api": "1.1.6",
62
- "@applitools/eyes-sdk-core": "12.24.0",
63
- "@applitools/spec-driver-playwright": "1.2.0",
64
- "@applitools/visual-grid-client": "15.8.44"
61
+ "@applitools/eyes-api": "1.3.0",
62
+ "@applitools/eyes-sdk-core": "13.3.5",
63
+ "@applitools/spec-driver-playwright": "1.3.0",
64
+ "@applitools/visual-grid-client": "15.12.6"
65
65
  },
66
66
  "devDependencies": {
67
- "@applitools/api-extractor": "1.2.2",
68
- "@applitools/scripts": "1.0.1",
69
- "@applitools/sdk-coverage-tests": "2.3.16",
70
- "@applitools/sdk-release-kit": "0.13.4",
71
- "@applitools/sdk-shared": "0.9.8",
72
- "@applitools/test-utils": "1.0.9",
67
+ "@applitools/api-extractor": "1.2.7",
68
+ "@applitools/bongo": "^2.0.3",
69
+ "@applitools/scripts": "1.1.0",
70
+ "@applitools/sdk-coverage-tests": "2.3.18",
71
+ "@applitools/sdk-shared": "0.9.11",
72
+ "@applitools/test-utils": "1.3.1",
73
73
  "@types/mocha": "^9.0.0",
74
74
  "@typescript-eslint/eslint-plugin": "^4.15.1",
75
75
  "@typescript-eslint/parser": "^4.15.1",
@@ -80,7 +80,7 @@
80
80
  "eslint-plugin-prettier": "^3.3.1",
81
81
  "husky": "^4.3.7",
82
82
  "mocha": "^8.0.1",
83
- "playwright": "1.15",
83
+ "playwright": "^1.16.3",
84
84
  "prettier": "^2.1.2",
85
85
  "spec-xunit-file": "0.0.1-3",
86
86
  "ts-node": "^10.2.1",
package/types/index.d.ts CHANGED
@@ -1,10 +1,10 @@
1
1
  export type Driver = import('playwright').Page & { __applitoolsBrand?: never; };
2
- export type Element = import('playwright').ElementHandle<Node> & { __applitoolsBrand?: never; };
3
- export type Selector = string & { __applitoolsBrand?: never; };
2
+ export type Element = import('playwright').ElementHandle & { __applitoolsBrand?: never; };
3
+ export type Selector = (string | import('playwright').Locator) & { __applitoolsBrand?: never; };
4
4
  export class Eyes {
5
5
  static setViewportSize: (driver: Driver, viewportSize: RectangleSize) => Promise<void>;
6
- constructor(runner: EyesRunner, config: ConfigurationPlain);
7
- constructor(config: ConfigurationPlain);
6
+ constructor(runner?: EyesRunner, config?: ConfigurationPlain);
7
+ constructor(config?: ConfigurationPlain);
8
8
  get logger(): Logger;
9
9
  getLogger(): Logger;
10
10
  get runner(): EyesRunner;
@@ -17,7 +17,7 @@ export class Eyes {
17
17
  setConfiguration(config: ConfigurationPlain): void;
18
18
  get isOpen(): boolean;
19
19
  getIsOpen(): boolean;
20
- on(handler: (event: string, data: Record<string, any>) => any): () => void;
20
+ on(handler: (event: string, data?: Record<string, any>) => any): () => void;
21
21
  on(event: "setSizeWillStart", handler: (data: { viewportSize: RectangleSizePlain; }) => any): () => void;
22
22
  on(event: "setSizeEnded", handler: () => any): () => void;
23
23
  on(event: "initStarted", handler: () => any): () => void;
@@ -27,23 +27,23 @@ export class Eyes {
27
27
  on(event: "validationEnded", handler: (data: { sessionId: string; validationId: number; validationResult: ValidationResultPlain; }) => any): () => void;
28
28
  on(event: "testEnded", handler: (data: { sessionId: string; testResults: TestResultsPlain; }) => any): () => void;
29
29
  off(event: string): void;
30
- off(handler: (args: Array<any>) => any): void;
31
- open(driver: Driver, config: ConfigurationPlain): Promise<Driver>;
32
- open(driver: Driver, appName: string, testName: string, viewportSize: RectangleSizePlain, sessionType: SessionTypePlain): Promise<Driver>;
33
- checkWindow(name: string, timeout: number, fully: boolean): Promise<MatchResult>;
34
- checkFrame(element: number | Element | EyesSelector<Selector>, timeout: number, name: string): Promise<MatchResult>;
35
- checkElement(element: Element, timeout: number, name: string): Promise<MatchResult>;
36
- checkElementBy(selector: EyesSelector<Selector>, timeout: number, name: string): Promise<MatchResult>;
37
- checkRegion(region: RegionPlain, name: string, timeout: number): Promise<MatchResult>;
38
- checkRegionByElement(element: Element, name: string, timeout: number): Promise<MatchResult>;
39
- checkRegionBy(selector: EyesSelector<Selector>, name: string, timeout: number, fully: boolean): Promise<MatchResult>;
40
- checkRegionInFrame(frame: number | Element | EyesSelector<Selector>, selector: EyesSelector<Selector>, timeout: number, name: string, fully: boolean): Promise<MatchResult>;
30
+ off(handler: (...args: Array<any>) => any): void;
31
+ open(driver: Driver, config?: ConfigurationPlain): Promise<Driver>;
32
+ open(driver: Driver, appName?: string, testName?: string, viewportSize?: RectangleSizePlain, sessionType?: SessionTypePlain): Promise<Driver>;
33
+ checkWindow(name?: string, timeout?: number, fully?: boolean): Promise<MatchResult>;
34
+ checkFrame(element: number | Element | EyesSelector<Selector>, timeout?: number, name?: string): Promise<MatchResult>;
35
+ checkElement(element: Element, timeout?: number, name?: string): Promise<MatchResult>;
36
+ checkElementBy(selector: EyesSelector<Selector>, timeout?: number, name?: string): Promise<MatchResult>;
37
+ checkRegion(region?: RegionPlain, name?: string, timeout?: number): Promise<MatchResult>;
38
+ checkRegionByElement(element: Element, name?: string, timeout?: number): Promise<MatchResult>;
39
+ checkRegionBy(selector: EyesSelector<Selector>, name?: string, timeout?: number, fully?: boolean): Promise<MatchResult>;
40
+ checkRegionInFrame(frame: number | Element | EyesSelector<Selector>, selector: EyesSelector<Selector>, timeout?: number, name?: string, fully?: boolean): Promise<MatchResult>;
41
41
  check(name: string, checkSettings: CheckSettings): Promise<MatchResult>;
42
- check(checkSettings: CheckSettingsPlain): Promise<MatchResult>;
42
+ check(checkSettings?: CheckSettingsPlain): Promise<MatchResult>;
43
43
  locate<TLocator extends string>(settings: VisualLocatorSettings<TLocator>): Promise<Record<TLocator, Array<RegionPlain>>>;
44
44
  extractTextRegions<TPattern extends string>(settings: OCRSettings<TPattern>): Promise<Record<TPattern, Array<TextRegion>>>;
45
45
  extractText(regions: Array<OCRRegion>): Promise<Array<string>>;
46
- close(throwErr: boolean): Promise<TestResults>;
46
+ close(throwErr?: boolean): Promise<TestResults>;
47
47
  closeAsync(): Promise<void>;
48
48
  abort(): Promise<TestResults>;
49
49
  abortAsync(): Promise<void>;
@@ -71,7 +71,7 @@ export class Eyes {
71
71
  clearProperties(): Configuration;
72
72
  getBatch(): BatchInfo;
73
73
  setBatch(batch: BatchInfoPlain): void;
74
- setBatch(name: string, id: string, startedAt: string | Date): void;
74
+ setBatch(name: string, id?: string, startedAt?: string | Date): void;
75
75
  getApiKey(): string;
76
76
  setApiKey(apiKey: string): void;
77
77
  getTestName(): string;
@@ -107,7 +107,7 @@ export class Eyes {
107
107
  getParentBranchName(): string;
108
108
  setParentBranchName(parentBranchName: string): void;
109
109
  setProxy(proxy: ProxySettingsPlain): void;
110
- setProxy(url: string, username: string, password: string, isHttpOnly: boolean): void;
110
+ setProxy(url: string, username?: string, password?: string, isHttpOnly?: boolean): void;
111
111
  setProxy(isEnabled: false): void;
112
112
  getProxy(): ProxySettings;
113
113
  getSaveDiffs(): boolean;
@@ -142,6 +142,7 @@ export type ConfigurationPlain = {
142
142
  apiKey?: string;
143
143
  serverUrl?: string;
144
144
  proxy?: ProxySettingsPlain;
145
+ autProxy?: { proxy: { url: string; username?: string; password?: string; isHttpOnly?: boolean; }; domains?: Array<string>; AUTProxyMode?: "Allow" | "Block"; };
145
146
  isDisabled?: boolean;
146
147
  connectionTimeout?: number;
147
148
  removeSession?: boolean;
@@ -166,6 +167,7 @@ export type ConfigurationPlain = {
166
167
  baselineBranchName?: string;
167
168
  compareWithParentBranch?: boolean;
168
169
  ignoreBaseline?: boolean;
170
+ ignoreGitMergeBase?: boolean;
169
171
  saveFailedTests?: boolean;
170
172
  saveNewTests?: boolean;
171
173
  saveDiffs?: boolean;
@@ -190,7 +192,7 @@ export type ConfigurationPlain = {
190
192
  disableBrowserFetching?: boolean;
191
193
  };
192
194
  export class Configuration implements Required<ConfigurationPlain> {
193
- constructor(config: ConfigurationPlain);
195
+ constructor(config?: ConfigurationPlain);
194
196
  get logs(): LogHandlerPlain;
195
197
  set logs(logs: LogHandlerPlain);
196
198
  getShowLogs(): boolean;
@@ -249,8 +251,12 @@ export class Configuration implements Required<ConfigurationPlain> {
249
251
  set proxy(proxy: ProxySettingsPlain);
250
252
  getProxy(): ProxySettings;
251
253
  setProxy(proxy: ProxySettingsPlain): Configuration;
252
- setProxy(url: string, username: string, password: string, isHttpOnly: boolean): Configuration;
254
+ setProxy(url: string, username?: string, password?: string, isHttpOnly?: boolean): Configuration;
253
255
  setProxy(isEnabled: false): Configuration;
256
+ get autProxy(): { proxy: { url: string; username?: string; password?: string; isHttpOnly?: boolean; }; domains?: Array<string>; AUTProxyMode?: "Allow" | "Block"; };
257
+ set autProxy(autProxy: { proxy: { url: string; username?: string; password?: string; isHttpOnly?: boolean; }; domains?: Array<string>; AUTProxyMode?: "Allow" | "Block"; });
258
+ getAutProxy(): { proxy: { url: string; username?: string; password?: string; isHttpOnly?: boolean; }; domains?: Array<string>; AUTProxyMode?: "Allow" | "Block"; };
259
+ setAutProxy(autProxy: { proxy: { url: string; username?: string; password?: string; isHttpOnly?: boolean; }; domains?: Array<string>; AUTProxyMode?: "Allow" | "Block"; }): Configuration;
254
260
  get connectionTimeout(): number;
255
261
  set connectionTimeout(connectionTimeout: number);
256
262
  getConnectionTimeout(): number;
@@ -298,6 +304,10 @@ export class Configuration implements Required<ConfigurationPlain> {
298
304
  set compareWithParentBranch(compareWithParentBranch: boolean);
299
305
  getCompareWithParentBranch(): boolean;
300
306
  setCompareWithParentBranch(compareWithParentBranch: boolean): Configuration;
307
+ get ignoreGitMergeBase(): boolean;
308
+ set ignoreGitMergeBase(ignoreGitMergeBase: boolean);
309
+ getIgnoreGitMergeBase(): boolean;
310
+ setIgnoreGitMergeBase(ignoreGitMergeBase: boolean): Configuration;
301
311
  get ignoreBaseline(): boolean;
302
312
  set ignoreBaseline(ignoreBaseline: boolean);
303
313
  getIgnoreBaseline(): boolean;
@@ -406,10 +416,10 @@ export class Configuration implements Required<ConfigurationPlain> {
406
416
  set browsersInfo(browsersInfo: Array<DesktopBrowserInfo | ChromeEmulationInfo | IOSDeviceInfo>);
407
417
  getBrowsersInfo(): Array<DesktopBrowserInfo | ChromeEmulationInfo | IOSDeviceInfo | { deviceName: DeviceNamePlain; screenOrientation?: ScreenOrientationPlain; }>;
408
418
  setBrowsersInfo(browsersInfo: Array<DesktopBrowserInfo | ChromeEmulationInfo | IOSDeviceInfo | { deviceName: DeviceNamePlain; screenOrientation?: ScreenOrientationPlain; }>): Configuration;
409
- addBrowsers(browsersInfo: Array<DesktopBrowserInfo | ChromeEmulationInfo | IOSDeviceInfo | { deviceName: DeviceNamePlain; screenOrientation?: ScreenOrientationPlain; }>): Configuration;
419
+ addBrowsers(...browsersInfo: Array<DesktopBrowserInfo | ChromeEmulationInfo | IOSDeviceInfo | { deviceName: DeviceNamePlain; screenOrientation?: ScreenOrientationPlain; }>): Configuration;
410
420
  addBrowser(browserInfo: DesktopBrowserInfo | ChromeEmulationInfo | IOSDeviceInfo | { deviceName: DeviceNamePlain; screenOrientation?: ScreenOrientationPlain; }): Configuration;
411
- addBrowser(width: number, height: number, name: BrowserTypePlain): Configuration;
412
- addDeviceEmulation(deviceName: DeviceNamePlain, screenOrientation: ScreenOrientationPlain): Configuration;
421
+ addBrowser(width: number, height: number, name?: BrowserTypePlain): Configuration;
422
+ addDeviceEmulation(deviceName: DeviceNamePlain, screenOrientation?: ScreenOrientationPlain): Configuration;
413
423
  get visualGridOptions(): { [key: string]: any; };
414
424
  set visualGridOptions(visualGridOptions: { [key: string]: any; });
415
425
  getVisualGridOptions(): { [key: string]: any; };
@@ -458,28 +468,29 @@ export type CheckSettingsPlain = {
458
468
  visualGridOptions?: { [key: string]: any; };
459
469
  hooks?: { beforeCaptureScreenshot: string; };
460
470
  renderId?: string;
471
+ pageId?: string;
461
472
  variationGroupId?: string;
462
473
  timeout?: number;
463
474
  waitBeforeCapture?: number;
464
475
  };
465
476
  export class CheckSettings {
466
- constructor(settings: CheckSettingsPlain);
477
+ constructor(settings?: CheckSettingsPlain);
467
478
  name(name: string): CheckSettings;
468
479
  withName(name: string): CheckSettings;
469
480
  region(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))): CheckSettings;
470
481
  shadow(selector: string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }): CheckSettings;
471
482
  frame(context: { frame: number | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })); scrollRootElement?: Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }); }): CheckSettings;
472
- frame(frame: number | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })), scrollRootElement: Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })): CheckSettings;
483
+ frame(frame: number | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })), scrollRootElement?: Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })): CheckSettings;
473
484
  ignoreRegion(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))): CheckSettings;
474
- ignoreRegions(regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
485
+ ignoreRegions(...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
475
486
  ignore(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))): CheckSettings;
476
- ignores(regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
487
+ ignores(...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
477
488
  layoutRegion(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))): CheckSettings;
478
- layoutRegions(regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
489
+ layoutRegions(...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
479
490
  strictRegion(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))): CheckSettings;
480
- strictRegions(regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
491
+ strictRegions(...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
481
492
  contentRegion(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))): CheckSettings;
482
- contentRegions(regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
493
+ contentRegions(...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
483
494
  floatingRegion(region: {
484
495
  region: RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }));
485
496
  maxUpOffset?: number;
@@ -487,15 +498,15 @@ export class CheckSettings {
487
498
  maxLeftOffset?: number;
488
499
  maxRightOffset?: number;
489
500
  }): CheckSettings;
490
- floatingRegion(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))), maxUpOffset: number, maxDownOffset: number, maxLeftOffset: number, maxRightOffset: number): CheckSettings;
491
- floatingRegions(regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))) | {
501
+ floatingRegion(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))), maxUpOffset?: number, maxDownOffset?: number, maxLeftOffset?: number, maxRightOffset?: number): CheckSettings;
502
+ floatingRegions(...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))) | {
492
503
  region: RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }));
493
504
  maxUpOffset?: number;
494
505
  maxDownOffset?: number;
495
506
  maxLeftOffset?: number;
496
507
  maxRightOffset?: number;
497
508
  }>): CheckSettings;
498
- floatingRegions(maxOffset: number, regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
509
+ floatingRegions(maxOffset: number, ...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
499
510
  floating(region: {
500
511
  region: RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }));
501
512
  maxUpOffset?: number;
@@ -504,39 +515,40 @@ export class CheckSettings {
504
515
  maxRightOffset?: number;
505
516
  }): CheckSettings;
506
517
  floating(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))): CheckSettings;
507
- floatings(regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))) | {
518
+ floatings(...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))) | {
508
519
  region: RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }));
509
520
  maxUpOffset?: number;
510
521
  maxDownOffset?: number;
511
522
  maxLeftOffset?: number;
512
523
  maxRightOffset?: number;
513
524
  }>): CheckSettings;
514
- floatings(maxOffset: number, regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
525
+ floatings(maxOffset: number, ...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
515
526
  accessibilityRegion(region: { region: RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })); type?: AccessibilityRegionTypePlain; }): CheckSettings;
516
- accessibilityRegion(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))), type: AccessibilityRegionTypePlain): CheckSettings;
517
- accessibilityRegions(regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))) | { region: RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })); type?: AccessibilityRegionTypePlain; }>): CheckSettings;
518
- accessibilityRegions(type: AccessibilityRegionTypePlain, regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
527
+ accessibilityRegion(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))), type?: AccessibilityRegionTypePlain): CheckSettings;
528
+ accessibilityRegions(...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }))) | { region: RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })); type?: AccessibilityRegionTypePlain; }>): CheckSettings;
529
+ accessibilityRegions(type: AccessibilityRegionTypePlain, ...regions: Array<LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))>): CheckSettings;
519
530
  scrollRootElement(scrollRootElement: Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })): CheckSettings;
520
- fully(fully: boolean): CheckSettings;
521
- stitchContent(stitchContent: boolean): CheckSettings;
531
+ fully(fully?: boolean): CheckSettings;
532
+ stitchContent(stitchContent?: boolean): CheckSettings;
522
533
  matchLevel(matchLevel: MatchLevelPlain): CheckSettings;
523
534
  layout(): CheckSettings;
524
535
  exact(): CheckSettings;
525
536
  strict(): CheckSettings;
526
537
  content(): CheckSettings;
527
- useDom(useDom: boolean): CheckSettings;
528
- sendDom(sendDom: boolean): CheckSettings;
529
- enablePatterns(enablePatterns: boolean): CheckSettings;
530
- ignoreDisplacements(ignoreDisplacements: boolean): CheckSettings;
531
- ignoreCaret(ignoreCaret: boolean): CheckSettings;
538
+ useDom(useDom?: boolean): CheckSettings;
539
+ sendDom(sendDom?: boolean): CheckSettings;
540
+ enablePatterns(enablePatterns?: boolean): CheckSettings;
541
+ ignoreDisplacements(ignoreDisplacements?: boolean): CheckSettings;
542
+ ignoreCaret(ignoreCaret?: boolean): CheckSettings;
532
543
  disableBrowserFetching(disableBrowserFetching: boolean): CheckSettings;
533
- layoutBreakpoints(layoutBreakpoints: boolean | Array<number>): CheckSettings;
544
+ layoutBreakpoints(layoutBreakpoints?: boolean | Array<number>): CheckSettings;
534
545
  hook(name: string, script: string): CheckSettings;
535
546
  beforeRenderScreenshotHook(script: string): CheckSettings;
536
547
  webHook(script: string): CheckSettings;
537
548
  visualGridOption(key: string, value: any): CheckSettings;
538
549
  visualGridOptions(options: { [key: string]: any; }): CheckSettings;
539
550
  renderId(renderId: string): CheckSettings;
551
+ pageId(pageId: string): CheckSettings;
540
552
  variationGroupId(variationGroupId: string): CheckSettings;
541
553
  timeout(timeout: number): CheckSettings;
542
554
  waitBeforeCapture(waitBeforeCapture: number): CheckSettings;
@@ -545,12 +557,12 @@ export const Target: {
545
557
  window(): CheckSettings;
546
558
  region(region: LegacyRegionPlain | (RegionPlain | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })))): CheckSettings;
547
559
  frame(context: { frame: number | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })); scrollRootElement?: Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }); }): CheckSettings;
548
- frame(frame: number | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })), scrollRootElement: Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })): CheckSettings;
560
+ frame(frame: number | (Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })), scrollRootElement?: Element | (string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; })): CheckSettings;
549
561
  shadow(selector: string | Selector | { selector: string | Selector; type?: string; shadow?: EyesSelector<Selector>; frame?: EyesSelector<Selector>; }): CheckSettings;
550
562
  };
551
563
  export class BatchClose {
552
564
  static close(settings: { batchIds: Array<string>; serverUrl?: string; apiKey?: string; proxy?: ProxySettingsPlain; }): Promise<void>;
553
- constructor(options: { batchIds: Array<string>; serverUrl?: string; apiKey?: string; proxy?: ProxySettingsPlain; });
565
+ constructor(options?: { batchIds: Array<string>; serverUrl?: string; apiKey?: string; proxy?: ProxySettingsPlain; });
554
566
  close(): Promise<void>;
555
567
  setBatchIds(batchIds: Array<string>): BatchClose;
556
568
  setUrl(serverUrl: string): BatchClose;
@@ -606,7 +618,7 @@ export enum CorsIframeHandle {
606
618
  KEEP = 'KEEP',
607
619
  SNAPSHOT = 'SNAPSHOT'
608
620
  }
609
- export type DeviceNamePlain = "Blackberry PlayBook" | "BlackBerry Z30" | "Galaxy A5" | "Galaxy Note 10" | "Galaxy Note 10 Plus" | "Galaxy Note 2" | "Galaxy Note 3" | "Galaxy Note 4" | "Galaxy Note 8" | "Galaxy Note 9" | "Galaxy S3" | "Galaxy S5" | "Galaxy S8" | "Galaxy S8 Plus" | "Galaxy S9" | "Galaxy S9 Plus" | "Galaxy S10" | "Galaxy S10 Plus" | "Galaxy S20" | "iPad" | "iPad 6th Gen" | "iPad 7th Gen" | "iPad Air 2" | "iPad Mini" | "iPad Pro" | "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone 4" | "iPhone 5/SE" | "iPhone 6/7/8" | "iPhone 6/7/8 Plus" | "iPhone X" | "iPhone XR" | "iPhone XS" | "iPhone XS Max" | "Kindle Fire HDX" | "Laptop with HiDPI screen" | "Laptop with MDPI screen" | "Laptop with touch" | "LG G6" | "LG Optimus L70" | "Microsoft Lumia 550" | "Microsoft Lumia 950" | "Nexus 10" | "Nexus 4" | "Nexus 5" | "Nexus 5X" | "Nexus 6" | "Nexus 6P" | "Nexus 7" | "Nokia Lumia 520" | "Nokia N9" | "OnePlus 7T" | "OnePlus 7T Pro" | "Pixel 2" | "Pixel 2 XL" | "Pixel 3" | "Pixel 3 XL" | "Pixel 4" | "Pixel 4 XL" | "Pixel 5";
621
+ export type DeviceNamePlain = "Blackberry PlayBook" | "BlackBerry Z30" | "Galaxy A5" | "Galaxy Note 10" | "Galaxy Note 10 Plus" | "Galaxy Note 2" | "Galaxy Note 3" | "Galaxy Note 4" | "Galaxy Note 8" | "Galaxy Note 9" | "Galaxy S3" | "Galaxy S5" | "Galaxy S8" | "Galaxy S8 Plus" | "Galaxy S9" | "Galaxy S9 Plus" | "Galaxy S10" | "Galaxy S10 Plus" | "Galaxy S20" | "Galaxy Tab S7" | "iPad" | "iPad 6th Gen" | "iPad 7th Gen" | "iPad Air 2" | "iPad Mini" | "iPad Pro" | "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone 4" | "iPhone 5/SE" | "iPhone 6/7/8" | "iPhone 6/7/8 Plus" | "iPhone X" | "iPhone XR" | "iPhone XS" | "iPhone XS Max" | "Kindle Fire HDX" | "Laptop with HiDPI screen" | "Laptop with MDPI screen" | "Laptop with touch" | "LG G6" | "LG Optimus L70" | "Microsoft Lumia 550" | "Microsoft Lumia 950" | "Nexus 10" | "Nexus 4" | "Nexus 5" | "Nexus 5X" | "Nexus 6" | "Nexus 6P" | "Nexus 7" | "Nokia Lumia 520" | "Nokia N9" | "OnePlus 7T" | "OnePlus 7T Pro" | "Pixel 2" | "Pixel 2 XL" | "Pixel 3" | "Pixel 3 XL" | "Pixel 4" | "Pixel 4 XL" | "Pixel 5";
610
622
  export enum DeviceName {
611
623
  Blackberry_PlayBook = 'Blackberry PlayBook',
612
624
  BlackBerry_Z30 = 'BlackBerry Z30',
@@ -627,6 +639,7 @@ export enum DeviceName {
627
639
  Galaxy_S10 = 'Galaxy S10',
628
640
  Galaxy_S10_Plus = 'Galaxy S10 Plus',
629
641
  Galaxy_S20 = 'Galaxy S20',
642
+ Galaxy_Tab_S7 = 'Galaxy Tab S7',
630
643
  iPad = 'iPad',
631
644
  iPad_6th_Gen = 'iPad 6th Gen',
632
645
  iPad_7th_Gen = 'iPad 7th Gen',
@@ -676,7 +689,7 @@ export enum FailureReport {
676
689
  IMMEDIATE = 'IMMEDIATE',
677
690
  ON_CLOSE = 'ON_CLOSE'
678
691
  }
679
- export type IosDeviceNamePlain = "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone X" | "iPhone XR" | "iPhone 13 Pro Max" | "iPhone 13 Pro" | "iPhone 13" | "iPhone 12 Pro Max" | "iPhone 12 Pro" | "iPhone 12" | "iPhone 12 mini" | "iPhone Xs" | "iPhone 8" | "iPhone 7" | "iPad Pro (12.9-inch) (3rd generation)" | "iPad (7th generation)" | "iPad (9th generation)" | "iPad Air (2nd generation)";
692
+ export type IosDeviceNamePlain = "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone X" | "iPhone XR" | "iPhone 13 Pro Max" | "iPhone 13 Pro" | "iPhone 13" | "iPhone 12 Pro Max" | "iPhone 12 Pro" | "iPhone 12" | "iPhone 12 mini" | "iPhone Xs" | "iPhone 8" | "iPhone 7" | "iPad Pro (12.9-inch) (3rd generation)" | "iPad (7th generation)" | "iPad (9th generation)" | "iPad Air (2nd generation)" | "iPad Air (4th generation)";
680
693
  export enum IosDeviceName {
681
694
  iPhone_13_Pro_Max = 'iPhone 13 Pro Max',
682
695
  iPhone_13_Pro = 'iPhone 13 Pro',
@@ -696,7 +709,8 @@ export enum IosDeviceName {
696
709
  iPad_Pro_3 = 'iPad Pro (12.9-inch) (3rd generation)',
697
710
  iPad_7 = 'iPad (7th generation)',
698
711
  iPad_9 = 'iPad (9th generation)',
699
- iPad_Air_2 = 'iPad Air (2nd generation)'
712
+ iPad_Air_2 = 'iPad Air (2nd generation)',
713
+ iPad_Air_4 = 'iPad Air (4th generation)'
700
714
  }
701
715
  export type IosVersionPlain = "latest" | "latest-1";
702
716
  export enum IosVersion {
@@ -738,24 +752,24 @@ export enum TestResultsStatus {
738
752
  export class EyesError extends Error {
739
753
  }
740
754
  export class TestFailedError extends EyesError {
741
- constructor(message: string, results: TestResultsPlain);
755
+ constructor(message: string, results?: TestResultsPlain);
742
756
  constructor(results: TestResultsPlain);
743
757
  get testResults(): TestResultsPlain;
744
758
  getTestResults(): TestResults;
745
759
  }
746
760
  export class DiffsFoundError extends TestFailedError {
747
- constructor(message: string, results: TestResultsPlain);
761
+ constructor(message: string, results?: TestResultsPlain);
748
762
  constructor(results: TestResultsPlain);
749
763
  }
750
764
  export class NewTestError extends TestFailedError {
751
- constructor(message: string, results: TestResultsPlain);
765
+ constructor(message: string, results?: TestResultsPlain);
752
766
  constructor(results: TestResultsPlain);
753
767
  }
754
768
  export type AccessibilityMatchSettingsPlain = { region: RegionPlain; type?: AccessibilityRegionTypePlain; };
755
769
  export class AccessibilityMatchSettings implements Required<AccessibilityMatchSettingsPlain> {
756
770
  constructor(settings: AccessibilityMatchSettingsPlain);
757
771
  constructor(region: RegionPlain);
758
- constructor(x: number, y: number, width: number, height: number, type: AccessibilityRegionTypePlain);
772
+ constructor(x: number, y: number, width: number, height: number, type?: AccessibilityRegionTypePlain);
759
773
  get region(): RegionPlain;
760
774
  set region(region: RegionPlain);
761
775
  getRegion(): Region;
@@ -784,8 +798,8 @@ export type BatchInfoPlain = {
784
798
  };
785
799
  export class BatchInfo implements Required<BatchInfoPlain> {
786
800
  constructor();
787
- constructor(batch: BatchInfoPlain);
788
- constructor(name: string, startedAt: string | Date, id: string);
801
+ constructor(batch?: BatchInfoPlain);
802
+ constructor(name?: string, startedAt?: string | Date, id?: string);
789
803
  get id(): string;
790
804
  set id(id: string);
791
805
  getId(): string;
@@ -810,7 +824,8 @@ export class BatchInfo implements Required<BatchInfoPlain> {
810
824
  set properties(properties: Array<PropertyDataPlain>);
811
825
  getProperties(): Array<PropertyData>;
812
826
  setProperties(properties: Array<PropertyDataPlain>): BatchInfo;
813
- addProperty(property: PropertyDataPlain): BatchInfo;
827
+ addProperty(name: string, value: string): BatchInfo;
828
+ addProperty(prop: PropertyDataPlain): BatchInfo;
814
829
  }
815
830
  export type CutProviderPlain = { top: number; right: number; bottom: number; left: number; } | { x: number; y: number; width: number; height: number; };
816
831
  export class CutProvider implements Required<{
@@ -870,7 +885,7 @@ export type FloatingMatchSettingsPlain = {
870
885
  export class FloatingMatchSettings implements Required<FloatingMatchSettingsPlain> {
871
886
  constructor(settings: FloatingMatchSettingsPlain);
872
887
  constructor(region: RegionPlain);
873
- constructor(x: number, y: number, width: number, height: number, maxUpOffset: number, maxDownOffset: number, maxLeftOffset: number, maxRightOffset: number);
888
+ constructor(x: number, y: number, width: number, height: number, maxUpOffset?: number, maxDownOffset?: number, maxLeftOffset?: number, maxRightOffset?: number);
874
889
  get region(): RegionPlain;
875
890
  set region(region: RegionPlain);
876
891
  getRegion(): Region;
@@ -916,7 +931,7 @@ export type ImageMatchSettingsPlain = {
916
931
  accessibilitySettings?: AccessibilitySettings;
917
932
  };
918
933
  export class ImageMatchSettings implements Required<ImageMatchSettingsPlain> {
919
- constructor(settings: ImageMatchSettingsPlain);
934
+ constructor(settings?: ImageMatchSettingsPlain);
920
935
  get exact(): ExactMatchSettingsPlain;
921
936
  set exact(exact: ExactMatchSettingsPlain);
922
937
  getExact(): ExactMatchSettings;
@@ -1013,7 +1028,7 @@ export type CustomLogHandlerPlain = {
1013
1028
  export type FileLogHandlerPlain = { type: "file"; filename?: string; append?: boolean; };
1014
1029
  export type ConsoleLogHandlerPlain = { type: "console"; };
1015
1030
  export abstract class LogHandler implements CustomLogHandlerPlain {
1016
- constructor(verbose: boolean);
1031
+ constructor(verbose?: boolean);
1017
1032
  get verbose(): boolean;
1018
1033
  set verbose(verbose: boolean);
1019
1034
  getIsVerbose(): boolean;
@@ -1024,7 +1039,7 @@ export abstract class LogHandler implements CustomLogHandlerPlain {
1024
1039
  abstract close(): void;
1025
1040
  }
1026
1041
  export class FileLogHandler extends LogHandler implements FileLogHandlerPlain {
1027
- constructor(verbose: boolean, filename: string, append: boolean);
1042
+ constructor(verbose?: boolean, filename?: string, append?: boolean);
1028
1043
  readonly type: "file";
1029
1044
  readonly filename: string;
1030
1045
  readonly append: boolean;
@@ -1060,7 +1075,7 @@ export class PropertyData implements Required<PropertyDataPlain> {
1060
1075
  export type ProxySettingsPlain = { url: string; username?: string; password?: string; isHttpOnly?: boolean; };
1061
1076
  export class ProxySettings implements Required<ProxySettingsPlain> {
1062
1077
  constructor(proxy: ProxySettingsPlain);
1063
- constructor(url: string, username: string, password: string, isHttpOnly: boolean);
1078
+ constructor(url: string, username?: string, password?: string, isHttpOnly?: boolean);
1064
1079
  get url(): string;
1065
1080
  getUri(): string;
1066
1081
  getUrl(): string;
@@ -1335,15 +1350,71 @@ export class TestResults implements Required<TestResultsPlain> {
1335
1350
  delete(): Promise<void>;
1336
1351
  deleteSession(): Promise<void>;
1337
1352
  }
1338
- export type TestResultContainerPlain = { readonly exception: Error; readonly testResults: TestResultsPlain; };
1353
+ export type TestResultContainerPlain = { readonly exception?: Error; readonly testResults?: {
1354
+ readonly id?: string;
1355
+ readonly name?: string;
1356
+ readonly secretToken?: string;
1357
+ readonly status?: "Passed" | "Failed" | "Unresolved";
1358
+ readonly appName?: string;
1359
+ readonly batchId?: string;
1360
+ readonly batchName?: string;
1361
+ readonly branchName?: string;
1362
+ readonly hostOS?: string;
1363
+ readonly hostApp?: string;
1364
+ readonly hostDisplaySize?: { width: number; height: number; };
1365
+ readonly accessibilityStatus?: { readonly level: "AA" | "AAA"; readonly version: "WCAG_2_0" | "WCAG_2_1"; readonly status: "Passed" | "Failed"; };
1366
+ readonly startedAt?: string | Date;
1367
+ readonly duration?: number;
1368
+ readonly isNew?: boolean;
1369
+ readonly isDifferent?: boolean;
1370
+ readonly isAborted?: boolean;
1371
+ readonly appUrls?: { readonly batch?: string; readonly session?: string; };
1372
+ readonly apiUrls?: { readonly batch?: string; readonly session?: string; };
1373
+ readonly stepsInfo?: Array<{
1374
+ readonly name?: string;
1375
+ readonly isDifferent?: boolean;
1376
+ readonly hasBaselineImage?: boolean;
1377
+ readonly hasCurrentImage?: boolean;
1378
+ readonly appUrls?: { readonly step?: string; readonly stepEditor?: string; };
1379
+ readonly apiUrls?: {
1380
+ readonly baselineImage?: string;
1381
+ readonly currentImage?: string;
1382
+ readonly checkpointImage?: string;
1383
+ readonly checkpointImageThumbnail?: string;
1384
+ readonly diffImage?: string;
1385
+ };
1386
+ readonly renderId?: Array<string>;
1387
+ }>;
1388
+ readonly steps?: number;
1389
+ readonly matches?: number;
1390
+ readonly mismatches?: number;
1391
+ readonly missing?: number;
1392
+ readonly exactMatches?: number;
1393
+ readonly strictMatches?: number;
1394
+ readonly contentMatches?: number;
1395
+ readonly layoutMatches?: number;
1396
+ readonly noneMatches?: number;
1397
+ readonly url?: string;
1398
+ }; readonly browserInfo?: { name?: "chrome" | "chrome-one-version-back" | "chrome-two-versions-back" | "firefox" | "firefox-one-version-back" | "firefox-two-versions-back" | "ie" | "ie10" | "edge" | "edgechromium" | "edgelegacy" | "edgechromium-one-version-back" | "edgechromium-two-versions-back" | "safari" | "safari-earlyaccess" | "safari-one-version-back" | "safari-two-versions-back"; width: number; height: number; } | { chromeEmulationInfo: { deviceName: "Blackberry PlayBook" | "BlackBerry Z30" | "Galaxy A5" | "Galaxy Note 10" | "Galaxy Note 10 Plus" | "Galaxy Note 2" | "Galaxy Note 3" | "Galaxy Note 4" | "Galaxy Note 8" | "Galaxy Note 9" | "Galaxy S3" | "Galaxy S5" | "Galaxy S8" | "Galaxy S8 Plus" | "Galaxy S9" | "Galaxy S9 Plus" | "Galaxy S10" | "Galaxy S10 Plus" | "Galaxy S20" | "Galaxy Tab S7" | "iPad" | "iPad 6th Gen" | "iPad 7th Gen" | "iPad Air 2" | "iPad Mini" | "iPad Pro" | "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone 4" | "iPhone 5/SE" | "iPhone 6/7/8" | "iPhone 6/7/8 Plus" | "iPhone X" | "iPhone XR" | "iPhone XS" | "iPhone XS Max" | "Kindle Fire HDX" | "Laptop with HiDPI screen" | "Laptop with MDPI screen" | "Laptop with touch" | "LG G6" | "LG Optimus L70" | "Microsoft Lumia 550" | "Microsoft Lumia 950" | "Nexus 10" | "Nexus 4" | "Nexus 5" | "Nexus 5X" | "Nexus 6" | "Nexus 6P" | "Nexus 7" | "Nokia Lumia 520" | "Nokia N9" | "OnePlus 7T" | "OnePlus 7T Pro" | "Pixel 2" | "Pixel 2 XL" | "Pixel 3" | "Pixel 3 XL" | "Pixel 4" | "Pixel 4 XL" | "Pixel 5"; screenOrientation?: "portrait" | "landscape"; }; } | { iosDeviceInfo: { deviceName: "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone X" | "iPhone XR" | "iPhone 13 Pro Max" | "iPhone 13 Pro" | "iPhone 13" | "iPhone 12 Pro Max" | "iPhone 12 Pro" | "iPhone 12" | "iPhone 12 mini" | "iPhone Xs" | "iPhone 8" | "iPhone 7" | "iPad Pro (12.9-inch) (3rd generation)" | "iPad (7th generation)" | "iPad (9th generation)" | "iPad Air (2nd generation)" | "iPad Air (4th generation)"; iosVersion?: "latest" | "latest-1"; screenOrientation?: "portrait" | "landscape"; }; }; };
1339
1399
  export class TestResultContainer implements Required<TestResultContainerPlain> {
1340
1400
  get testResults(): TestResultsPlain;
1341
1401
  getTestResults(): TestResults;
1342
1402
  get exception(): Error;
1343
1403
  getException(): Error;
1404
+ get browserInfo(): { name?: "chrome" | "chrome-one-version-back" | "chrome-two-versions-back" | "firefox" | "firefox-one-version-back" | "firefox-two-versions-back" | "ie" | "ie10" | "edge" | "edgechromium" | "edgelegacy" | "edgechromium-one-version-back" | "edgechromium-two-versions-back" | "safari" | "safari-earlyaccess" | "safari-one-version-back" | "safari-two-versions-back"; width: number; height: number; } | { chromeEmulationInfo: { deviceName: "Blackberry PlayBook" | "BlackBerry Z30" | "Galaxy A5" | "Galaxy Note 10" | "Galaxy Note 10 Plus" | "Galaxy Note 2" | "Galaxy Note 3" | "Galaxy Note 4" | "Galaxy Note 8" | "Galaxy Note 9" | "Galaxy S3" | "Galaxy S5" | "Galaxy S8" | "Galaxy S8 Plus" | "Galaxy S9" | "Galaxy S9 Plus" | "Galaxy S10" | "Galaxy S10 Plus" | "Galaxy S20" | "Galaxy Tab S7" | "iPad" | "iPad 6th Gen" | "iPad 7th Gen" | "iPad Air 2" | "iPad Mini" | "iPad Pro" | "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone 4" | "iPhone 5/SE" | "iPhone 6/7/8" | "iPhone 6/7/8 Plus" | "iPhone X" | "iPhone XR" | "iPhone XS" | "iPhone XS Max" | "Kindle Fire HDX" | "Laptop with HiDPI screen" | "Laptop with MDPI screen" | "Laptop with touch" | "LG G6" | "LG Optimus L70" | "Microsoft Lumia 550" | "Microsoft Lumia 950" | "Nexus 10" | "Nexus 4" | "Nexus 5" | "Nexus 5X" | "Nexus 6" | "Nexus 6P" | "Nexus 7" | "Nokia Lumia 520" | "Nokia N9" | "OnePlus 7T" | "OnePlus 7T Pro" | "Pixel 2" | "Pixel 2 XL" | "Pixel 3" | "Pixel 3 XL" | "Pixel 4" | "Pixel 4 XL" | "Pixel 5"; screenOrientation?: "portrait" | "landscape"; }; } | { iosDeviceInfo: { deviceName: "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone X" | "iPhone XR" | "iPhone 13 Pro Max" | "iPhone 13 Pro" | "iPhone 13" | "iPhone 12 Pro Max" | "iPhone 12 Pro" | "iPhone 12" | "iPhone 12 mini" | "iPhone Xs" | "iPhone 8" | "iPhone 7" | "iPad Pro (12.9-inch) (3rd generation)" | "iPad (7th generation)" | "iPad (9th generation)" | "iPad Air (2nd generation)" | "iPad Air (4th generation)"; iosVersion?: "latest" | "latest-1"; screenOrientation?: "portrait" | "landscape"; }; };
1405
+ getBrowserInfo(): { name?: "chrome" | "chrome-one-version-back" | "chrome-two-versions-back" | "firefox" | "firefox-one-version-back" | "firefox-two-versions-back" | "ie" | "ie10" | "edge" | "edgechromium" | "edgelegacy" | "edgechromium-one-version-back" | "edgechromium-two-versions-back" | "safari" | "safari-earlyaccess" | "safari-one-version-back" | "safari-two-versions-back"; width: number; height: number; } | { chromeEmulationInfo: { deviceName: "Blackberry PlayBook" | "BlackBerry Z30" | "Galaxy A5" | "Galaxy Note 10" | "Galaxy Note 10 Plus" | "Galaxy Note 2" | "Galaxy Note 3" | "Galaxy Note 4" | "Galaxy Note 8" | "Galaxy Note 9" | "Galaxy S3" | "Galaxy S5" | "Galaxy S8" | "Galaxy S8 Plus" | "Galaxy S9" | "Galaxy S9 Plus" | "Galaxy S10" | "Galaxy S10 Plus" | "Galaxy S20" | "Galaxy Tab S7" | "iPad" | "iPad 6th Gen" | "iPad 7th Gen" | "iPad Air 2" | "iPad Mini" | "iPad Pro" | "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone 4" | "iPhone 5/SE" | "iPhone 6/7/8" | "iPhone 6/7/8 Plus" | "iPhone X" | "iPhone XR" | "iPhone XS" | "iPhone XS Max" | "Kindle Fire HDX" | "Laptop with HiDPI screen" | "Laptop with MDPI screen" | "Laptop with touch" | "LG G6" | "LG Optimus L70" | "Microsoft Lumia 550" | "Microsoft Lumia 950" | "Nexus 10" | "Nexus 4" | "Nexus 5" | "Nexus 5X" | "Nexus 6" | "Nexus 6P" | "Nexus 7" | "Nokia Lumia 520" | "Nokia N9" | "OnePlus 7T" | "OnePlus 7T Pro" | "Pixel 2" | "Pixel 2 XL" | "Pixel 3" | "Pixel 3 XL" | "Pixel 4" | "Pixel 4 XL" | "Pixel 5"; screenOrientation?: "portrait" | "landscape"; }; } | { iosDeviceInfo: { deviceName: "iPhone 11" | "iPhone 11 Pro" | "iPhone 11 Pro Max" | "iPhone X" | "iPhone XR" | "iPhone 13 Pro Max" | "iPhone 13 Pro" | "iPhone 13" | "iPhone 12 Pro Max" | "iPhone 12 Pro" | "iPhone 12" | "iPhone 12 mini" | "iPhone Xs" | "iPhone 8" | "iPhone 7" | "iPad Pro (12.9-inch) (3rd generation)" | "iPad (7th generation)" | "iPad (9th generation)" | "iPad Air (2nd generation)" | "iPad Air (4th generation)"; iosVersion?: "latest" | "latest-1"; screenOrientation?: "portrait" | "landscape"; }; };
1344
1406
  }
1345
- export type TestResultsSummaryPlain = Iterable<TestResultContainerPlain>;
1346
- export class TestResultsSummary implements TestResultsSummaryPlain {
1407
+ export type TestResultsSummaryPlain = {
1408
+ results: Array<TestResultContainerPlain>;
1409
+ passed: number;
1410
+ unresolved: number;
1411
+ failed: number;
1412
+ exceptions: number;
1413
+ mismatches: number;
1414
+ missing: number;
1415
+ matches: number;
1416
+ };
1417
+ export class TestResultsSummary implements Iterable<TestResultContainerPlain> {
1347
1418
  getAllResults(): Array<TestResultContainer>;
1348
1419
  [Symbol.iterator](): Iterator<TestResultContainer, any, undefined>;
1349
1420
  }
@@ -1368,29 +1439,64 @@ export class ValidationResult implements Required<ValidationResultPlain> {
1368
1439
  }
1369
1440
  export type EyesSelector<TSelector = never> = string | TSelector | { selector: string | TSelector; type?: string; shadow?: EyesSelector<TSelector>; frame?: EyesSelector<TSelector>; };
1370
1441
  export class Logger {
1371
- constructor(options: { show?: boolean; label?: string; handler?: LogHandlerPlain; });
1372
- constructor(show: boolean);
1442
+ constructor(options?: { show?: boolean; label?: string; handler?: LogHandlerPlain; });
1443
+ constructor(show?: boolean);
1373
1444
  getLogHandler(): LogHandler;
1374
1445
  setLogHandler(handler: LogHandlerPlain): void;
1375
- verbose(messages: Array<any>): void;
1376
- log(messages: Array<any>): void;
1377
- warn(messages: Array<any>): void;
1378
- error(messages: Array<any>): void;
1379
- fatal(messages: Array<any>): void;
1446
+ verbose(...messages: Array<any>): void;
1447
+ log(...messages: Array<any>): void;
1448
+ warn(...messages: Array<any>): void;
1449
+ error(...messages: Array<any>): void;
1450
+ fatal(...messages: Array<any>): void;
1380
1451
  open(): void;
1381
1452
  close(): void;
1382
- extend(label: string, color: string | Array<string>): Logger;
1453
+ extend(options?: Omit<{
1454
+ handler?: CustomLogHandlerPlain | FileLogHandlerPlain | ConsoleLogHandlerPlain | {
1455
+ type: "rolling file";
1456
+ dirname?: string;
1457
+ name?: string;
1458
+ maxFileLength?: number;
1459
+ maxFileNumber?: number;
1460
+ };
1461
+ format?: (message: any, options: {
1462
+ formatting?: boolean;
1463
+ label?: string;
1464
+ timestamp?: Date;
1465
+ level?: "silent" | "fatal" | "error" | "warn" | "info";
1466
+ tags?: Record<string, unknown>;
1467
+ color?: string | Array<string>;
1468
+ colors?: { timestamp?: string | Array<string>; level?: {
1469
+ silent?: string | Array<string>;
1470
+ fatal?: string | Array<string>;
1471
+ error?: string | Array<string>;
1472
+ warn?: string | Array<string>;
1473
+ info?: string | Array<string>;
1474
+ }; tags?: string | Array<string>; message?: string | Array<string>; };
1475
+ }) => string;
1476
+ label?: string;
1477
+ timestamp?: false;
1478
+ level?: number | ("silent" | "fatal" | "error" | "warn" | "info");
1479
+ colors?: boolean | { timestamp?: string | Array<string>; level?: {
1480
+ silent?: string | Array<string>;
1481
+ fatal?: string | Array<string>;
1482
+ error?: string | Array<string>;
1483
+ warn?: string | Array<string>;
1484
+ info?: string | Array<string>;
1485
+ }; tags?: string | Array<string>; message?: string | Array<string>; };
1486
+ console?: boolean | CustomLogHandlerPlain;
1487
+ }, "handler">): Logger;
1488
+ extend(label?: string): Logger;
1383
1489
  }
1384
1490
  export function closeBatch(spec: { closeBatches(options: { settings: { batchIds: Array<string>; serverUrl?: string; apiKey?: string; proxy?: ProxySettingsPlain; }; }): Promise<void>; }): (options: { batchIds: Array<string>; serverUrl?: string; apiKey?: string; proxy?: ProxySettingsPlain; }) => Promise<void>;
1385
1491
  export abstract class EyesRunner {
1386
- getAllTestResults(throwErr: boolean): Promise<TestResultsSummary>;
1492
+ getAllTestResults(throwErr?: boolean): Promise<TestResultsSummary>;
1387
1493
  }
1388
1494
  export class ClassicRunner extends EyesRunner {
1389
1495
  }
1390
1496
  export class VisualGridRunner extends EyesRunner {
1391
- constructor(options: RunnerOptionsPlain);
1392
- constructor(options: RunnerOptionsFluent);
1393
- constructor(legacyConcurrency: number);
1497
+ constructor(options?: RunnerOptionsPlain);
1498
+ constructor(options?: RunnerOptionsFluent);
1499
+ constructor(legacyConcurrency?: number);
1394
1500
  get testConcurrency(): number;
1395
1501
  get legacyConcurrency(): number;
1396
1502
  getConcurrentSessions(): number;
@@ -1420,7 +1526,7 @@ export class SessionEventHandlers extends SessionEventHandler {
1420
1526
  }
1421
1527
  export class RemoteSessionEventHandler extends SessionEventHandler {
1422
1528
  constructor(options: { serverUrl: string; accessKey?: string; timeout?: number; });
1423
- constructor(serverUrl: string, accessKey: string, timeout: number);
1529
+ constructor(serverUrl: string, accessKey?: string, timeout?: number);
1424
1530
  get serverUrl(): string;
1425
1531
  set serverUrl(serverUrl: string);
1426
1532
  getServerUrl(): string;