@empiricalrun/playwright-utils 0.66.0 → 0.66.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/dist/generated/api-worker-openapi.d.ts +424 -61
- package/dist/generated/api-worker-openapi.d.ts.map +1 -1
- package/dist/test/constants.d.ts +1 -0
- package/dist/test/constants.d.ts.map +1 -1
- package/dist/test/constants.js +2 -1
- package/dist/test/cross-shard-locks.d.ts +1 -1
- package/dist/test/cross-shard-locks.d.ts.map +1 -1
- package/dist/test/cross-shard-locks.js +2 -2
- package/package.json +4 -4
package/dist/test/constants.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/test/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gCAAgC,MAAM,CAAC"}
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/test/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gCAAgC,MAAM,CAAC;AAEpD,eAAO,MAAM,mBAAmB,8BAA8B,CAAC"}
|
package/dist/test/constants.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.DEFAULT_SCRIPT_EXECUTION_TIMEOUT = void 0;
|
|
3
|
+
exports.TEST_LOCKS_FILE_ENV = exports.DEFAULT_SCRIPT_EXECUTION_TIMEOUT = void 0;
|
|
4
4
|
exports.DEFAULT_SCRIPT_EXECUTION_TIMEOUT = 500;
|
|
5
|
+
exports.TEST_LOCKS_FILE_ENV = "EMPIRICAL_TEST_LOCKS_FILE";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { TestLocksByTestId } from "@empiricalrun/shared-types/playwright-utils";
|
|
2
2
|
import type { TestInfo } from "@playwright/test";
|
|
3
3
|
import { type KVClient } from "../kv";
|
|
4
4
|
type LockKv = Pick<KVClient, "set" | "refresh" | "delete">;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cross-shard-locks.d.ts","sourceRoot":"","sources":["../../src/test/cross-shard-locks.ts"],"names":[],"mappings":"AAGA,OAAO,
|
|
1
|
+
{"version":3,"file":"cross-shard-locks.d.ts","sourceRoot":"","sources":["../../src/test/cross-shard-locks.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,6CAA6C,CAAC;AACrF,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAEjD,OAAO,EAAE,KAAK,QAAQ,EAA6B,MAAM,OAAO,CAAC;AAGjE,KAAK,MAAM,GAAG,IAAI,CAAC,QAAQ,EAAE,KAAK,GAAG,SAAS,GAAG,QAAQ,CAAC,CAAC;AAI3D,eAAO,MAAM,kBAAkB,KAAK,CAAC;AAkBrC,wBAAgB,YAAY,CAC1B,MAAM,EAAE,MAAM,EACd,KAAK,GAAE,iBACa,GACnB,MAAM,EAAE,CAEV;AAED,wBAAgB,OAAO,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,CAI3D;AAuBD,wBAAsB,SAAS,CAAC,EAC9B,EAAE,EACF,KAAK,EACL,KAAK,EACL,MAAM,EACN,QAAQ,EACR,GAAc,EACd,KAAiE,GAClE,EAAE;IACD,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,CAAC,UAAU,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,WAAW,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAC;IACtE,GAAG,CAAC,EAAE,MAAM,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CACvC,GAAG,OAAO,CAAC,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC,CA6C/B;AAED,wBAAsB,mBAAmB,CACvC,QAAQ,EAAE,QAAQ,EAClB,QAAQ,EAAE,MAAM,MAAM,GACrB,OAAO,CAAC,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC,CAmB9B"}
|
|
@@ -10,14 +10,14 @@ exports.holdLocks = holdLocks;
|
|
|
10
10
|
exports.holdCrossShardLocks = holdCrossShardLocks;
|
|
11
11
|
const node_crypto_1 = require("node:crypto");
|
|
12
12
|
const node_fs_1 = __importDefault(require("node:fs"));
|
|
13
|
-
const playwright_utils_1 = require("@empiricalrun/shared-types/playwright-utils");
|
|
14
13
|
const kv_1 = require("../kv");
|
|
14
|
+
const constants_1 = require("./constants");
|
|
15
15
|
exports.LOCK_LEASE_SECONDS = 60;
|
|
16
16
|
const RENEW_EVERY_MS = 20_000;
|
|
17
17
|
const MAX_POLL_MS = 2_000;
|
|
18
18
|
let sharedLocks;
|
|
19
19
|
function readSharedLocks() {
|
|
20
|
-
const file = process.env[
|
|
20
|
+
const file = process.env[constants_1.TEST_LOCKS_FILE_ENV];
|
|
21
21
|
if (!file) {
|
|
22
22
|
return {};
|
|
23
23
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@empiricalrun/playwright-utils",
|
|
3
|
-
"version": "0.66.
|
|
3
|
+
"version": "0.66.1",
|
|
4
4
|
"engines": {
|
|
5
5
|
"node": ">=22"
|
|
6
6
|
},
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"playwright-core": "1.63.0",
|
|
46
46
|
"serve-handler": "^6.1.6",
|
|
47
47
|
"typescript": "7.0.2",
|
|
48
|
-
"@empiricalrun/shared-types": "0.23.
|
|
48
|
+
"@empiricalrun/shared-types": "0.23.3"
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
51
51
|
"async-retry": "^1.3.3",
|
|
@@ -56,9 +56,9 @@
|
|
|
56
56
|
"openapi-fetch": "0.14.1",
|
|
57
57
|
"puppeteer-extra-plugin-recaptcha": "^3.6.8",
|
|
58
58
|
"ts-morph": "^28.0.0",
|
|
59
|
+
"@empiricalrun/cua": "^0.6.0",
|
|
59
60
|
"@empiricalrun/r2-uploader": "^0.11.5",
|
|
60
|
-
"@empiricalrun/reporter": "^0.30.3"
|
|
61
|
-
"@empiricalrun/cua": "^0.6.0"
|
|
61
|
+
"@empiricalrun/reporter": "^0.30.3"
|
|
62
62
|
},
|
|
63
63
|
"scripts": {
|
|
64
64
|
"dev": "pnpm gen:api-worker-openapi && tsc --build --watch",
|