@argos-ci/playwright 3.9.0 → 3.9.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.cjs +0 -12
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -3,15 +3,3 @@ const argosScreenshot = async (...args) => {
|
|
|
3
3
|
return argosScreenshot(...args);
|
|
4
4
|
};
|
|
5
5
|
exports.argosScreenshot = argosScreenshot;
|
|
6
|
-
|
|
7
|
-
const getCSPScriptHash = async (...args) => {
|
|
8
|
-
const { getCSPScriptHash } = await import("./index.js");
|
|
9
|
-
return getCSPScriptHash(...args);
|
|
10
|
-
};
|
|
11
|
-
exports.getCSPScriptHash = getCSPScriptHash;
|
|
12
|
-
|
|
13
|
-
const DO_NOT_USE_setMetadataConfig = async (...args) => {
|
|
14
|
-
const { DO_NOT_USE_setMetadataConfig } = await import("./index.js");
|
|
15
|
-
return DO_NOT_USE_setMetadataConfig(...args);
|
|
16
|
-
};
|
|
17
|
-
exports.DO_NOT_USE_setMetadataConfig = DO_NOT_USE_setMetadataConfig;
|
package/dist/index.d.ts
CHANGED
|
@@ -66,7 +66,7 @@ options?: ArgosScreenshotOptions): Promise<void>;
|
|
|
66
66
|
/**
|
|
67
67
|
* Get the CSP script hash.
|
|
68
68
|
*/
|
|
69
|
-
declare function getCSPScriptHash():
|
|
69
|
+
declare function getCSPScriptHash(): string;
|
|
70
70
|
|
|
71
71
|
type MetadataConfig = {
|
|
72
72
|
sdk: ScreenshotMetadata["sdk"];
|
|
@@ -75,6 +75,6 @@ type MetadataConfig = {
|
|
|
75
75
|
/**
|
|
76
76
|
* Set the metadata config.
|
|
77
77
|
*/
|
|
78
|
-
declare function setMetadataConfig(metadata: MetadataConfig):
|
|
78
|
+
declare function setMetadataConfig(metadata: MetadataConfig): void;
|
|
79
79
|
|
|
80
80
|
export { type ArgosScreenshotOptions, setMetadataConfig as DO_NOT_USE_setMetadataConfig, argosScreenshot, getCSPScriptHash };
|
package/dist/index.js
CHANGED
|
@@ -34,7 +34,7 @@ function tryResolve(pkg) {
|
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
36
|
var metadataConfigStorage = new AsyncLocalStorage();
|
|
37
|
-
|
|
37
|
+
function setMetadataConfig(metadata) {
|
|
38
38
|
metadataConfigStorage.enterWith(metadata);
|
|
39
39
|
}
|
|
40
40
|
var DEFAULT_PLAYWRIGHT_LIBRARIES = [
|
|
@@ -315,7 +315,7 @@ ${reasons.map((reason) => `- ${reason}`).join("\n")}
|
|
|
315
315
|
// src/csp.ts
|
|
316
316
|
import { getGlobalScript as getGlobalScript2 } from "@argos-ci/browser";
|
|
317
317
|
import { createHash } from "node:crypto";
|
|
318
|
-
|
|
318
|
+
function getCSPScriptHash() {
|
|
319
319
|
const hash = createHash("sha256").update(getGlobalScript2()).digest("base64");
|
|
320
320
|
return `'sha256-${hash}'`;
|
|
321
321
|
}
|
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": "3.9.
|
|
4
|
+
"version": "3.9.1",
|
|
5
5
|
"author": "Smooth Code",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
@@ -65,5 +65,5 @@
|
|
|
65
65
|
"test": "pnpm exec -- playwright test",
|
|
66
66
|
"e2e": "UPLOAD_TO_ARGOS=true pnpm run test"
|
|
67
67
|
},
|
|
68
|
-
"gitHead": "
|
|
68
|
+
"gitHead": "2df737ab2349a7b2c4afcae71266c40902c7561c"
|
|
69
69
|
}
|