@argos-ci/playwright 6.6.4 → 7.0.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/dist/index.d.mts +1 -1
- package/dist/reporter.d.mts +26 -3
- package/package.json +8 -8
package/dist/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ScreenshotMetadata } from "@argos-ci/util";
|
|
2
2
|
import { StabilizationPluginOptions, ViewportOption } from "@argos-ci/browser";
|
|
3
3
|
import { ElementHandle, Frame, Locator, LocatorScreenshotOptions, Page, PageScreenshotOptions } from "@playwright/test";
|
|
4
|
-
//#region ../../node_modules/.pnpm/playwright@1.
|
|
4
|
+
//#region ../../node_modules/.pnpm/playwright@1.59.1/node_modules/playwright/types/test.d.ts
|
|
5
5
|
// --- BEGINGLOBAL ---
|
|
6
6
|
declare global {
|
|
7
7
|
export namespace PlaywrightTest {
|
package/dist/reporter.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { UploadParameters } from "@argos-ci/core";
|
|
2
2
|
import { BrowserContextOptions, Geolocation, HTTPCredentials, LaunchOptions, PageScreenshotOptions, ViewportSize } from "playwright-core";
|
|
3
3
|
|
|
4
|
-
//#region ../../node_modules/.pnpm/playwright@1.
|
|
4
|
+
//#region ../../node_modules/.pnpm/playwright@1.59.1/node_modules/playwright/types/test.d.ts
|
|
5
5
|
type BlobReporterOptions = {
|
|
6
6
|
outputDir?: string;
|
|
7
7
|
fileName?: string;
|
|
@@ -13,6 +13,7 @@ type JUnitReporterOptions = {
|
|
|
13
13
|
outputFile?: string;
|
|
14
14
|
stripANSIControlSequences?: boolean;
|
|
15
15
|
includeProjectInTestName?: boolean;
|
|
16
|
+
includeRetries?: boolean;
|
|
16
17
|
};
|
|
17
18
|
type JsonReporterOptions = {
|
|
18
19
|
outputFile?: string;
|
|
@@ -26,6 +27,7 @@ type HtmlReporterOptions = {
|
|
|
26
27
|
title?: string;
|
|
27
28
|
noSnippets?: boolean;
|
|
28
29
|
noCopyPrompt?: boolean;
|
|
30
|
+
doNotInlineAssets?: boolean;
|
|
29
31
|
};
|
|
30
32
|
type ReporterDescription = Readonly<['blob'] | ['blob', BlobReporterOptions] | ['dot'] | ['line'] | ['list'] | ['list', ListReporterOptions] | ['github'] | ['junit'] | ['junit', JUnitReporterOptions] | ['json'] | ['json', JsonReporterOptions] | ['html'] | ['html', HtmlReporterOptions] | ['null'] | [string] | [string, any]>;
|
|
31
33
|
type UseOptions<TestArgs, WorkerArgs> = Partial<WorkerArgs> & Partial<TestArgs>;
|
|
@@ -106,6 +108,10 @@ interface FullProject<TestArgs = {}, WorkerArgs = {}> {
|
|
|
106
108
|
* See [testProject.grepInvert](https://playwright.dev/docs/api/class-testproject#test-project-grep-invert).
|
|
107
109
|
*/
|
|
108
110
|
grepInvert: null | RegExp | Array<RegExp>;
|
|
111
|
+
/**
|
|
112
|
+
* See [testProject.ignoreSnapshots](https://playwright.dev/docs/api/class-testproject#test-project-ignore-snapshots).
|
|
113
|
+
*/
|
|
114
|
+
ignoreSnapshots: boolean;
|
|
109
115
|
/**
|
|
110
116
|
* See [testProject.metadata](https://playwright.dev/docs/api/class-testproject#test-project-metadata).
|
|
111
117
|
*/
|
|
@@ -510,6 +516,7 @@ interface PlaywrightWorkerOptions {
|
|
|
510
516
|
* - `'retain-on-failure'`: Record trace for each test. When test run passes, remove the recorded trace.
|
|
511
517
|
* - `'retain-on-first-failure'`: Record trace for the first run of each test, but not for retries. When test run
|
|
512
518
|
* passes, remove the recorded trace.
|
|
519
|
+
* - `'retain-on-failure-and-retries'`: Record trace for each test run. Retains all traces when an attempt fails.
|
|
513
520
|
*
|
|
514
521
|
* For more control, pass an object that specifies `mode` and trace features to enable.
|
|
515
522
|
*
|
|
@@ -547,6 +554,10 @@ interface PlaywrightWorkerOptions {
|
|
|
547
554
|
* down to fit into 800x800. If `viewport` is not configured explicitly the video size defaults to 800x450. Actual
|
|
548
555
|
* picture of each page will be scaled down if necessary to fit the specified size.
|
|
549
556
|
*
|
|
557
|
+
* To annotate actions in the video, pass `show` with `action` and/or `test` sub-options. The `action` option controls
|
|
558
|
+
* visual highlights on interacted elements with an optional `delay` in milliseconds (defaults to `500`). The `test`
|
|
559
|
+
* option controls which test information is displayed as a status overlay.
|
|
560
|
+
*
|
|
550
561
|
* **Usage**
|
|
551
562
|
*
|
|
552
563
|
* ```js
|
|
@@ -565,10 +576,22 @@ interface PlaywrightWorkerOptions {
|
|
|
565
576
|
video: VideoMode | /** deprecated */'retry-with-video' | {
|
|
566
577
|
mode: VideoMode;
|
|
567
578
|
size?: ViewportSize;
|
|
579
|
+
show?: {
|
|
580
|
+
actions?: {
|
|
581
|
+
duration?: number;
|
|
582
|
+
position?: 'top-left' | 'top' | 'top-right' | 'bottom-left' | 'bottom' | 'bottom-right';
|
|
583
|
+
fontSize?: number;
|
|
584
|
+
};
|
|
585
|
+
test?: {
|
|
586
|
+
level?: 'file' | 'title' | 'step';
|
|
587
|
+
position?: 'top-left' | 'top' | 'top-right' | 'bottom-left' | 'bottom' | 'bottom-right';
|
|
588
|
+
fontSize?: number;
|
|
589
|
+
};
|
|
590
|
+
};
|
|
568
591
|
};
|
|
569
592
|
}
|
|
570
593
|
type ScreenshotMode = 'off' | 'on' | 'only-on-failure' | 'on-first-failure';
|
|
571
|
-
type TraceMode = 'off' | 'on' | 'retain-on-failure' | 'on-first-retry' | 'on-all-retries' | 'retain-on-first-failure';
|
|
594
|
+
type TraceMode = 'off' | 'on' | 'retain-on-failure' | 'on-first-retry' | 'on-all-retries' | 'retain-on-first-failure' | 'retain-on-failure-and-retries';
|
|
572
595
|
type VideoMode = 'off' | 'on' | 'retain-on-failure' | 'on-first-retry';
|
|
573
596
|
/**
|
|
574
597
|
* Playwright Test provides many options to configure test environment,
|
|
@@ -1287,7 +1310,7 @@ interface TestConfigWebServer {
|
|
|
1287
1310
|
url?: string;
|
|
1288
1311
|
}
|
|
1289
1312
|
//#endregion
|
|
1290
|
-
//#region ../../node_modules/.pnpm/playwright@1.
|
|
1313
|
+
//#region ../../node_modules/.pnpm/playwright@1.59.1/node_modules/playwright/types/testReporter.d.ts
|
|
1291
1314
|
/**
|
|
1292
1315
|
* Result of the full test run.
|
|
1293
1316
|
*/
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@argos-ci/playwright",
|
|
3
3
|
"description": "Playwright SDK for visual testing with Argos.",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "7.0.1",
|
|
5
5
|
"author": "Smooth Code",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
@@ -44,24 +44,24 @@
|
|
|
44
44
|
"./package.json": "./package.json"
|
|
45
45
|
},
|
|
46
46
|
"engines": {
|
|
47
|
-
"node": ">=
|
|
47
|
+
"node": ">=22.0.0"
|
|
48
48
|
},
|
|
49
49
|
"dependencies": {
|
|
50
|
-
"@argos-ci/browser": "
|
|
51
|
-
"@argos-ci/core": "
|
|
52
|
-
"@argos-ci/util": "
|
|
50
|
+
"@argos-ci/browser": "6.0.0",
|
|
51
|
+
"@argos-ci/core": "6.0.1",
|
|
52
|
+
"@argos-ci/util": "4.0.0",
|
|
53
53
|
"chalk": "^5.6.2",
|
|
54
54
|
"debug": "^4.4.3"
|
|
55
55
|
},
|
|
56
56
|
"devDependencies": {
|
|
57
|
-
"@playwright/test": "^1.
|
|
57
|
+
"@playwright/test": "^1.59.1",
|
|
58
58
|
"@types/debug": "^4.1.13",
|
|
59
59
|
"@types/node": "catalog:",
|
|
60
60
|
"vitest": "catalog:"
|
|
61
61
|
},
|
|
62
62
|
"scripts": {
|
|
63
63
|
"build": "tsdown && cp ./src/index.cjs ./dist",
|
|
64
|
-
"test-e2e": "
|
|
64
|
+
"test-e2e": "playwright test",
|
|
65
65
|
"build-e2e": "playwright install chromium --with-deps",
|
|
66
66
|
"e2e": "UPLOAD_TO_ARGOS=true pnpm run test-e2e",
|
|
67
67
|
"check-types": "tsc",
|
|
@@ -69,5 +69,5 @@
|
|
|
69
69
|
"lint": "eslint .",
|
|
70
70
|
"test": "vitest src"
|
|
71
71
|
},
|
|
72
|
-
"gitHead": "
|
|
72
|
+
"gitHead": "75892460d881beaf87ae6a6c62c2c82d5df8fba4"
|
|
73
73
|
}
|