@flemist/simple-utils 2.1.2 → 2.1.4
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/build/browser/index.cjs +1 -1
- package/build/browser/index.mjs +148 -115
- package/build/common/index.cjs +1 -1
- package/build/common/index.mjs +148 -115
- package/build/common/string/format/index.d.ts +1 -0
- package/build/common/test/index.d.ts +1 -0
- package/build/common/test/match/Matcher.d.ts +14 -0
- package/build/common/test/match/check.d.ts +9 -0
- package/build/common/test/match/helpers.d.ts +4 -0
- package/build/common/test/match/index.d.ts +7 -0
- package/build/common/test/match/match.d.ts +6 -0
- package/build/common/test/match/matchers/MatchInstanceOf.d.ts +11 -0
- package/build/common/test/match/matchers/MatcherAny.d.ts +6 -0
- package/build/common/test/match/matchers/MatcherArray.d.ts +12 -0
- package/build/common/test/match/matchers/MatcherArrayItem.d.ts +10 -0
- package/build/common/test/match/matchers/MatcherConvert.d.ts +10 -0
- package/build/common/test/match/matchers/MatcherCustom.d.ts +9 -0
- package/build/common/test/match/matchers/MatcherFew.d.ts +13 -0
- package/build/common/test/match/matchers/MatcherIn.d.ts +12 -0
- package/build/common/test/match/matchers/MatcherIs.d.ts +10 -0
- package/build/common/test/match/matchers/MatcherNever.d.ts +6 -0
- package/build/common/test/match/matchers/MatcherNot.d.ts +9 -0
- package/build/common/test/match/matchers/MatcherNumber.d.ts +15 -0
- package/build/common/test/match/matchers/MatcherObject.d.ts +14 -0
- package/build/common/test/match/matchers/MatcherObjectEntry.d.ts +11 -0
- package/build/common/test/match/matchers/MatcherRef.d.ts +10 -0
- package/build/common/test/match/matchers/MatcherString.d.ts +10 -0
- package/build/common/test/match/matchers/constants.d.ts +1 -0
- package/build/common/test/match/matchers/index.d.ts +18 -0
- package/build/common/test/match/matchers/matchers.d.ts +92 -0
- package/build/common/test/match/report.d.ts +5 -0
- package/build/common/test/match/types.d.ts +24 -0
- package/build/node/index.cjs +7 -7
- package/build/node/index.mjs +510 -477
- package/build/node/test/e2e/check/checkPageHttpErrors.d.ts +25 -0
- package/build/node/test/e2e/check/index.d.ts +3 -0
- package/build/node/test/e2e/check/subscribeJsErrors.d.ts +10 -0
- package/build/node/test/e2e/check/types.d.ts +1 -0
- package/build/node/test/e2e/index.d.ts +3 -0
- package/build/node/test/e2e/setPlaywrightPriorityLow.d.ts +1 -0
- package/build/node/test/e2e/test/delayOnError.d.ts +3 -0
- package/build/node/test/e2e/test/index.d.ts +6 -0
- package/build/node/test/e2e/test/initPage.d.ts +25 -0
- package/build/node/test/e2e/test/testPage.d.ts +17 -0
- package/build/node/test/e2e/test/types.d.ts +7 -0
- package/build/node/test/e2e/test/useBrowser.d.ts +5 -0
- package/build/node/test/e2e/test/useBrowserContext.d.ts +5 -0
- package/build/node/test/index.d.ts +2 -0
- package/build/node/test/refactor/createPagesElementsChangesTest.d.ts +11 -0
- package/build/node/test/refactor/forcePseudoClasses.d.ts +5 -0
- package/build/node/test/refactor/getAllElements.d.ts +2 -0
- package/build/node/test/refactor/getElementsStyleDiff.d.ts +2 -0
- package/build/node/test/refactor/getObjectsDiff.d.ts +6 -0
- package/build/node/test/refactor/index.d.ts +7 -0
- package/build/node/test/refactor/loadSaveJson.d.ts +2 -0
- package/build/node/test/refactor/types.d.ts +72 -0
- package/build/urlGet-CerQ1cKh.js +17 -0
- package/build/{urlGet-BCW9jvAm.mjs → urlGet-DZEwtNXt.mjs} +614 -561
- package/package.json +1 -1
- package/build/urlGet-BOGFUahf.js +0 -17
package/build/node/index.mjs
CHANGED
|
@@ -1,44 +1,44 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { Locker as wt, useAbortController as
|
|
4
|
-
import { Pool as
|
|
5
|
-
import
|
|
6
|
-
import * as
|
|
1
|
+
import { V as mt, S as pt, F as yt } from "../urlGet-DZEwtNXt.mjs";
|
|
2
|
+
import { ac as he, M as de, W as me, X as pe, P as ye, aj as we, a2 as be, a3 as ge, b5 as xe, b6 as Ee, b7 as Se, b8 as ke, b9 as Oe, ba as je, bb as Ce, bk as Pe, bc as Ae, bd as Le, be as Te, bf as Me, bg as De, bh as Fe, bi as Ie, bj as Re, R as _e, $ as Ne, a0 as We, U as $e, L as Be, H as ze, a6 as Je, ad as Ue, ae as ve, K as He, I as Ge, N as Ke, q as Ve, aa as Ye, a9 as qe, a8 as Xe, Z as Qe, l as Ze, o as tr, B as er, C as rr, D as nr, E as sr, z as ar, A as or, a5 as ir, ag as cr, af as lr, Q as ur, u as fr, v as hr, w as dr, J as mr, p as pr, x as yr, d as wr, g as br, a4 as gr, _ as xr, ab as Er, aH as Sr, aJ as kr, am as Or, ak as jr, b4 as Cr, al as Pr, ap as Ar, aL as Lr, aO as Tr, aD as Mr, aC as Dr, aq as Fr, aZ as Ir, ax as Rr, aY as _r, av as Nr, aX as Wr, aA as $r, au as Br, a_ as zr, as as Jr, ar as Ur, ao as vr, b1 as Hr, aF as Gr, aE as Kr, at as Vr, aw as Yr, aR as qr, aS as Xr, aT as Qr, aV as Zr, aP as tn, aW as en, ay as rn, aU as nn, aQ as sn, aN as an, aK as on, aG as cn, aI as ln, a$ as un, b0 as fn, an as hn, ah as dn, ai as mn, az as pn, aM as yn, aB as wn, b2 as bn, b3 as gn, b as xn, m as En, c as Sn, n as kn, f as On, k as jn, r as Cn, h as Pn, e as An, i as Ln, j as Tn, G as Mn, a as Dn, s as Fn, T as In, t as Rn, y as _n, bq as Nn, bs as Wn, br as $n, bl as Bn, bp as zn, bm as Jn, bo as Un, bn as vn, a7 as Hn, a1 as Gn, O as Kn, Y as Vn } from "../urlGet-DZEwtNXt.mjs";
|
|
3
|
+
import { Locker as wt, useAbortController as bt, combineAbortSignals as st, delay as at } from "@flemist/async-utils";
|
|
4
|
+
import { Pool as gt, poolRunWait as N } from "@flemist/time-limits";
|
|
5
|
+
import xt from "node:os";
|
|
6
|
+
import * as D from "path";
|
|
7
7
|
import ot from "path";
|
|
8
8
|
import { priorityCreate as z } from "@flemist/priority-queue";
|
|
9
|
-
import * as
|
|
10
|
-
import
|
|
11
|
-
import { spawn as
|
|
12
|
-
import { AbortControllerFast as
|
|
13
|
-
const Z = new xt
|
|
14
|
-
function
|
|
9
|
+
import * as F from "fs";
|
|
10
|
+
import Et from "picomatch";
|
|
11
|
+
import { spawn as v } from "child_process";
|
|
12
|
+
import { AbortControllerFast as St } from "@flemist/abort-controller-fast";
|
|
13
|
+
const Z = new gt(xt.cpus().length);
|
|
14
|
+
function W(t) {
|
|
15
15
|
return t.replace(/\\/g, "/");
|
|
16
16
|
}
|
|
17
17
|
let U = null;
|
|
18
18
|
function kt(t) {
|
|
19
19
|
U == null && (U = /* @__PURE__ */ new Map());
|
|
20
|
-
const e =
|
|
21
|
-
let
|
|
22
|
-
return
|
|
20
|
+
const e = W(t);
|
|
21
|
+
let n = U.get(e);
|
|
22
|
+
return n == null && (n = new wt(), U.set(e, n)), n;
|
|
23
23
|
}
|
|
24
|
-
function
|
|
25
|
-
const { filePath: e, func:
|
|
24
|
+
function Qt(t) {
|
|
25
|
+
const { filePath: e, func: n } = t;
|
|
26
26
|
return kt(e).lock(
|
|
27
27
|
() => N({
|
|
28
28
|
pool: Z,
|
|
29
29
|
count: 1,
|
|
30
|
-
func:
|
|
30
|
+
func: n
|
|
31
31
|
})
|
|
32
32
|
);
|
|
33
33
|
}
|
|
34
34
|
function Ot(t) {
|
|
35
35
|
return t.match(/^[/\\]?[^/\\]+/)[0];
|
|
36
36
|
}
|
|
37
|
-
function
|
|
37
|
+
function jt(t, e) {
|
|
38
38
|
return Ot(t) + "|" + e.ino;
|
|
39
39
|
}
|
|
40
|
-
function
|
|
41
|
-
return t.endsWith(":") && (t += "/"),
|
|
40
|
+
function Ct(t) {
|
|
41
|
+
return t.endsWith(":") && (t += "/"), D.resolve(t);
|
|
42
42
|
}
|
|
43
43
|
function et(t, e) {
|
|
44
44
|
t.totalSize += e.totalSize, t.maxFileDateModified = Math.max(
|
|
@@ -46,7 +46,7 @@ function et(t, e) {
|
|
|
46
46
|
e.maxFileDateModified
|
|
47
47
|
), t.countFiles += e.countFiles, t.countDirs += e.countDirs, t.countLinks += e.countLinks;
|
|
48
48
|
}
|
|
49
|
-
const
|
|
49
|
+
const Pt = function(e) {
|
|
50
50
|
return e.code === "ENOENT";
|
|
51
51
|
};
|
|
52
52
|
function it(t) {
|
|
@@ -59,36 +59,36 @@ function it(t) {
|
|
|
59
59
|
countDirs: 0,
|
|
60
60
|
countLinks: 0
|
|
61
61
|
});
|
|
62
|
-
const
|
|
63
|
-
async function y(
|
|
64
|
-
if (!(o && await o(
|
|
65
|
-
throw
|
|
62
|
+
const n = t.level ?? 0, s = t.walkedIds ?? /* @__PURE__ */ new Set(), r = t.abortSignal, a = t.pool ?? Z, o = t.handleError, i = t.priority ?? z(0), u = t.walkLinks ?? !1, c = t.log, x = t.handlePath, f = t.matchPath;
|
|
63
|
+
async function y(h) {
|
|
64
|
+
if (!(o && await o(h)) && !Pt(h))
|
|
65
|
+
throw h;
|
|
66
66
|
}
|
|
67
|
-
function
|
|
68
|
-
return !(!c || c.minTotalContentSize != null &&
|
|
67
|
+
function j(h) {
|
|
68
|
+
return !(!c || c.minTotalContentSize != null && h < c.minTotalContentSize || c.maxNestedLevel != null && n > c.maxNestedLevel);
|
|
69
69
|
}
|
|
70
|
-
return
|
|
71
|
-
const w = st(
|
|
70
|
+
return bt(async (h) => {
|
|
71
|
+
const w = st(r, h), m = {
|
|
72
72
|
totalSize: 0,
|
|
73
73
|
maxFileDateModified: 0,
|
|
74
74
|
countFiles: 0,
|
|
75
75
|
countDirs: 0,
|
|
76
76
|
countLinks: 0
|
|
77
77
|
};
|
|
78
|
-
function
|
|
79
|
-
if (
|
|
80
|
-
const
|
|
81
|
-
c?.handleLog ? c.handleLog(
|
|
78
|
+
function T(g, O) {
|
|
79
|
+
if (j(O.totalSize)) {
|
|
80
|
+
const b = `${O.totalSize.toLocaleString("en-US").replace(/,/g, " ").padStart(19)}: ${g}`;
|
|
81
|
+
c?.handleLog ? c.handleLog(b) : console.log(b);
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
|
-
async function l(
|
|
85
|
-
return
|
|
84
|
+
async function l(g, O, p, b) {
|
|
85
|
+
return x ? await N({
|
|
86
86
|
pool: a,
|
|
87
87
|
func: async () => {
|
|
88
88
|
try {
|
|
89
|
-
return await
|
|
90
|
-
level:
|
|
91
|
-
path:
|
|
89
|
+
return await x({
|
|
90
|
+
level: n,
|
|
91
|
+
path: g,
|
|
92
92
|
stat: O,
|
|
93
93
|
itemStat: p,
|
|
94
94
|
totalStat: m,
|
|
@@ -99,26 +99,26 @@ function it(t) {
|
|
|
99
99
|
}
|
|
100
100
|
},
|
|
101
101
|
count: 1,
|
|
102
|
-
priority:
|
|
102
|
+
priority: b,
|
|
103
103
|
abortSignal: w
|
|
104
104
|
}) : !0;
|
|
105
105
|
}
|
|
106
|
-
async function
|
|
107
|
-
|
|
106
|
+
async function E(g, O, p, b) {
|
|
107
|
+
b || (b = g);
|
|
108
108
|
const k = await N({
|
|
109
109
|
pool: a,
|
|
110
|
-
func: () =>
|
|
110
|
+
func: () => F.promises.lstat(g).catch(y),
|
|
111
111
|
count: 1,
|
|
112
112
|
priority: z(O, z(1, i)),
|
|
113
113
|
abortSignal: w
|
|
114
114
|
});
|
|
115
115
|
if (!k || !p && k.isFile())
|
|
116
116
|
return null;
|
|
117
|
-
const
|
|
118
|
-
if (s.has(
|
|
117
|
+
const P = jt(g, k);
|
|
118
|
+
if (s.has(P))
|
|
119
119
|
return null;
|
|
120
|
-
s.add(
|
|
121
|
-
let
|
|
120
|
+
s.add(P);
|
|
121
|
+
let d = {
|
|
122
122
|
totalSize: k.size,
|
|
123
123
|
maxFileDateModified: k.isDirectory() ? 0 : k.mtimeMs,
|
|
124
124
|
countFiles: 0,
|
|
@@ -131,63 +131,63 @@ function it(t) {
|
|
|
131
131
|
);
|
|
132
132
|
if (k.isSymbolicLink()) {
|
|
133
133
|
if (u) {
|
|
134
|
-
const
|
|
134
|
+
const C = await N({
|
|
135
135
|
pool: a,
|
|
136
|
-
func: () =>
|
|
136
|
+
func: () => F.promises.readlink(g).catch(y).then((M) => M ?? null),
|
|
137
137
|
count: 1,
|
|
138
138
|
priority: A,
|
|
139
139
|
abortSignal: w
|
|
140
140
|
});
|
|
141
|
-
if (
|
|
142
|
-
const
|
|
143
|
-
|
|
141
|
+
if (C) {
|
|
142
|
+
const M = D.isAbsolute(C) ? C : D.resolve(D.dirname(b), C), I = await E(
|
|
143
|
+
M,
|
|
144
144
|
O,
|
|
145
145
|
p,
|
|
146
|
-
|
|
146
|
+
b
|
|
147
147
|
);
|
|
148
|
-
|
|
148
|
+
I && (d = I);
|
|
149
149
|
}
|
|
150
150
|
}
|
|
151
|
-
return (p ||
|
|
152
|
-
|
|
151
|
+
return (p || d.countFiles + d.countDirs + d.countLinks >= 1) && (d.countLinks += 1, await l(
|
|
152
|
+
b,
|
|
153
153
|
k,
|
|
154
|
-
|
|
154
|
+
d,
|
|
155
155
|
A
|
|
156
|
-
) && (et(m,
|
|
156
|
+
) && (et(m, d), T(b, d))), d;
|
|
157
157
|
} else if (k.isDirectory()) {
|
|
158
|
-
const
|
|
158
|
+
const C = await N({
|
|
159
159
|
pool: a,
|
|
160
|
-
func: () =>
|
|
160
|
+
func: () => F.promises.readdir(g).catch(y),
|
|
161
161
|
count: 1,
|
|
162
162
|
priority: i,
|
|
163
163
|
abortSignal: w
|
|
164
164
|
});
|
|
165
|
-
if (
|
|
166
|
-
for (let
|
|
167
|
-
|
|
168
|
-
|
|
165
|
+
if (C) {
|
|
166
|
+
for (let M = 0, I = C.length; M < I; M++)
|
|
167
|
+
C[M] = D.join(b, C[M]);
|
|
168
|
+
d = await it({
|
|
169
169
|
...t,
|
|
170
|
-
paths:
|
|
170
|
+
paths: C,
|
|
171
171
|
abortSignal: w,
|
|
172
172
|
priority: A,
|
|
173
|
-
level:
|
|
173
|
+
level: n + 1,
|
|
174
174
|
walkedIds: s
|
|
175
175
|
});
|
|
176
176
|
}
|
|
177
177
|
}
|
|
178
|
-
return (p ||
|
|
179
|
-
|
|
178
|
+
return (p || d.countFiles + d.countDirs + d.countLinks >= 1) && (k.isDirectory() ? d.countDirs += 1 : k.isFile() && (d.countFiles += 1), await l(
|
|
179
|
+
b,
|
|
180
180
|
k,
|
|
181
|
-
|
|
181
|
+
d,
|
|
182
182
|
A
|
|
183
|
-
) && (et(m,
|
|
183
|
+
) && (et(m, d), T(b, d))), d;
|
|
184
184
|
}
|
|
185
|
-
const
|
|
186
|
-
for (let
|
|
187
|
-
const p =
|
|
188
|
-
|
|
185
|
+
const S = [];
|
|
186
|
+
for (let g = 0, O = e.length; g < O; g++) {
|
|
187
|
+
const p = Ct(e[g]), b = f ? f(p) : !0;
|
|
188
|
+
b !== !1 && S.push(E(p, g, b));
|
|
189
189
|
}
|
|
190
|
-
return await Promise.all(
|
|
190
|
+
return await Promise.all(S), m;
|
|
191
191
|
});
|
|
192
192
|
}
|
|
193
193
|
function Zt(t) {
|
|
@@ -196,33 +196,33 @@ function Zt(t) {
|
|
|
196
196
|
function te({
|
|
197
197
|
globs: t,
|
|
198
198
|
rootDir: e,
|
|
199
|
-
noCase:
|
|
199
|
+
noCase: n
|
|
200
200
|
}) {
|
|
201
201
|
const s = [];
|
|
202
|
-
return t.forEach((
|
|
203
|
-
|
|
204
|
-
const a =
|
|
205
|
-
a && (
|
|
206
|
-
const o =
|
|
207
|
-
if (o && (
|
|
202
|
+
return t.forEach((r) => {
|
|
203
|
+
r = W(r).trim();
|
|
204
|
+
const a = r.startsWith("^");
|
|
205
|
+
a && (r = r.substring(1).trim());
|
|
206
|
+
const o = r.startsWith("!");
|
|
207
|
+
if (o && (r = r.substring(1).trim()), r.startsWith("!") || r.startsWith("^"))
|
|
208
208
|
throw new Error(
|
|
209
|
-
`Invalid glob pattern: "${
|
|
209
|
+
`Invalid glob pattern: "${r}". The syntax '${r.substring(0, 2)}' is not supported. Valid glob patterns use: * (match any characters), ** (match any directories), ? (match single character), [abc] (character class), ! (negate pattern), ^ (exclude if included). Examples of valid patterns: "*.js", "src/**/*.ts", "!node_modules", "^dist". Avoid starting with '!' after '^' or multiple special prefixes.`
|
|
210
210
|
);
|
|
211
|
-
|
|
212
|
-
const i =
|
|
211
|
+
r.startsWith("/") && (r = "." + r);
|
|
212
|
+
const i = W(e ? D.resolve(e, r) : r);
|
|
213
213
|
if (!i)
|
|
214
214
|
return;
|
|
215
215
|
let u;
|
|
216
216
|
try {
|
|
217
|
-
u =
|
|
218
|
-
nocase:
|
|
217
|
+
u = Et(i, {
|
|
218
|
+
nocase: n ?? !1,
|
|
219
219
|
dot: !0,
|
|
220
220
|
strictBrackets: !0
|
|
221
221
|
// Validate bracket balance for patterns like "["
|
|
222
222
|
});
|
|
223
223
|
} catch (c) {
|
|
224
224
|
throw new Error(
|
|
225
|
-
`Invalid glob pattern: "${
|
|
225
|
+
`Invalid glob pattern: "${r}". ${c instanceof Error ? c.message : "Unknown error"}. Valid glob patterns use: * (match any characters), ** (match any directories), ? (match single character), [abc] (character class with balanced brackets), ! (negate pattern), ^ (exclude if included). Examples: "*.js", "src/**/*.ts", "!node_modules", "[abc]def.txt". Ensure all brackets [ ] are properly closed and balanced.`
|
|
226
226
|
);
|
|
227
227
|
}
|
|
228
228
|
s.push({
|
|
@@ -232,11 +232,11 @@ function te({
|
|
|
232
232
|
match: u
|
|
233
233
|
});
|
|
234
234
|
}), function(a) {
|
|
235
|
-
a =
|
|
235
|
+
a = W(a);
|
|
236
236
|
let o = null, i = !1;
|
|
237
237
|
for (let u = 0, c = s.length; u < c; u++) {
|
|
238
|
-
const
|
|
239
|
-
|
|
238
|
+
const x = s[u];
|
|
239
|
+
x.match(a) && (x.exclude ? i = !x.negative : (o = !x.negative, i = !1));
|
|
240
240
|
}
|
|
241
241
|
return i ? !1 : o;
|
|
242
242
|
};
|
|
@@ -248,76 +248,76 @@ function At(t) {
|
|
|
248
248
|
function Lt(t, e) {
|
|
249
249
|
if (!e || e === ".")
|
|
250
250
|
return t;
|
|
251
|
-
const
|
|
252
|
-
|
|
251
|
+
const n = t.startsWith("^");
|
|
252
|
+
n && (t = t.substring(1));
|
|
253
253
|
const s = t.startsWith("!");
|
|
254
|
-
return s && (t = t.substring(1)), t.startsWith("/") ? (e.endsWith("/") && (e = e.substring(0, e.length - 1)), t = e + t) : (e.endsWith("/") || (e += "/"), t.startsWith("./") ? t = e + t.substring(2) : t.startsWith("../") ? t = e + t : (e.startsWith("..") && (e = ""), t.startsWith("**") ? t = e + t : t = e + "**/" + t)), t =
|
|
254
|
+
return s && (t = t.substring(1)), t.startsWith("/") ? (e.endsWith("/") && (e = e.substring(0, e.length - 1)), t = e + t) : (e.endsWith("/") || (e += "/"), t.startsWith("./") ? t = e + t.substring(2) : t.startsWith("../") ? t = e + t : (e.startsWith("..") && (e = ""), t.startsWith("**") ? t = e + t : t = e + "**/" + t)), t = W(D.normalize(t)), s && (t = "!" + t), n && (t = "^" + t), t;
|
|
255
255
|
}
|
|
256
|
-
function
|
|
256
|
+
function rt(t) {
|
|
257
257
|
return "^" + t;
|
|
258
258
|
}
|
|
259
|
-
async function
|
|
260
|
-
const
|
|
259
|
+
async function Tt(t) {
|
|
260
|
+
const n = (await F.promises.readFile(t, "utf-8")).split(`
|
|
261
261
|
`), s = [];
|
|
262
|
-
return
|
|
263
|
-
|
|
262
|
+
return n.forEach((r) => {
|
|
263
|
+
r = r.trim(), !(!r || r.startsWith("#")) && s.push(r);
|
|
264
264
|
}), s;
|
|
265
265
|
}
|
|
266
266
|
async function ee(t) {
|
|
267
|
-
const e = t.rootDir ?? ".",
|
|
267
|
+
const e = t.rootDir ?? ".", n = [];
|
|
268
268
|
if (!t.globs?.length)
|
|
269
|
-
return
|
|
269
|
+
return n;
|
|
270
270
|
const s = [];
|
|
271
|
-
return t.globs.forEach((
|
|
272
|
-
|
|
271
|
+
return t.globs.forEach((r) => {
|
|
272
|
+
r.value && (r.valueType === "file-contains-patterns" ? s.push(r) : r.valueType === "pattern" && n.push(r.exclude ? rt(r.value) : r.value));
|
|
273
273
|
}), s.length && await Promise.all(
|
|
274
|
-
s.map(async (
|
|
274
|
+
s.map(async (r) => {
|
|
275
275
|
await N({
|
|
276
276
|
pool: Z,
|
|
277
277
|
count: 1,
|
|
278
278
|
func: async () => {
|
|
279
|
-
const a =
|
|
279
|
+
const a = D.resolve(e, r.value), o = await Tt(a), i = D.relative(e, D.dirname(a));
|
|
280
280
|
o.forEach((u) => {
|
|
281
|
-
u = At(u), u = Lt(u, i),
|
|
281
|
+
u = At(u), u = Lt(u, i), n.push(r.exclude ? rt(u) : u);
|
|
282
282
|
});
|
|
283
283
|
}
|
|
284
284
|
});
|
|
285
285
|
})
|
|
286
|
-
),
|
|
286
|
+
), n;
|
|
287
287
|
}
|
|
288
|
-
function
|
|
289
|
-
return new Promise((
|
|
290
|
-
const
|
|
288
|
+
function Mt(t, e = {}) {
|
|
289
|
+
return new Promise((n, s) => {
|
|
290
|
+
const r = v(t, {
|
|
291
291
|
shell: !0,
|
|
292
292
|
...e
|
|
293
293
|
}), a = [];
|
|
294
|
-
|
|
294
|
+
r.stdout.on("data", (o) => {
|
|
295
295
|
a.push(o);
|
|
296
|
-
}),
|
|
296
|
+
}), r.on("error", (o) => {
|
|
297
297
|
s(o);
|
|
298
|
-
}),
|
|
298
|
+
}), r.on("exit", (o) => {
|
|
299
299
|
const i = Buffer.concat(a).toString("utf8");
|
|
300
300
|
if (o !== 0) {
|
|
301
301
|
s(new Error(`[exec][exit] code: ${o}`));
|
|
302
302
|
return;
|
|
303
303
|
}
|
|
304
|
-
|
|
304
|
+
n(i);
|
|
305
305
|
});
|
|
306
306
|
});
|
|
307
307
|
}
|
|
308
|
-
async function
|
|
308
|
+
async function re() {
|
|
309
309
|
let t;
|
|
310
310
|
switch (process.platform) {
|
|
311
311
|
case "darwin":
|
|
312
|
-
t =
|
|
312
|
+
t = v("afplay", ["/System/Library/Sounds/Ping.aiff"], {
|
|
313
313
|
stdio: "ignore"
|
|
314
314
|
});
|
|
315
315
|
break;
|
|
316
316
|
case "linux":
|
|
317
|
-
t =
|
|
317
|
+
t = v("beep", [], { stdio: "ignore", shell: !0 });
|
|
318
318
|
break;
|
|
319
319
|
case "win32":
|
|
320
|
-
t =
|
|
320
|
+
t = v("powershell", ["-c", "[console]::beep(1000,300)"], {
|
|
321
321
|
stdio: "ignore"
|
|
322
322
|
});
|
|
323
323
|
break;
|
|
@@ -326,34 +326,34 @@ async function ne() {
|
|
|
326
326
|
`[nodeBeep] Beep not supported on platform: ${process.platform}`
|
|
327
327
|
);
|
|
328
328
|
}
|
|
329
|
-
await new Promise((e,
|
|
330
|
-
t.on("error",
|
|
331
|
-
s !== 0 ?
|
|
329
|
+
await new Promise((e, n) => {
|
|
330
|
+
t.on("error", n), t.on("close", (s) => {
|
|
331
|
+
s !== 0 ? n(new Error(`[nodeBeep] Beep process exited with code ${s}`)) : e();
|
|
332
332
|
});
|
|
333
333
|
});
|
|
334
334
|
}
|
|
335
|
-
async function
|
|
335
|
+
async function Dt({
|
|
336
336
|
page: t,
|
|
337
337
|
urlFilters: e,
|
|
338
|
-
timeouts:
|
|
338
|
+
timeouts: n
|
|
339
339
|
}) {
|
|
340
|
-
return
|
|
340
|
+
return n || (n = {}), n.downloadInternal || (n.downloadInternal = 10 * 1e3), n.downloadExternal || (n.downloadExternal = 60 * 1e3), n.total || (n.total = 300 * 1e3), await mt(
|
|
341
341
|
() => t.evaluate(
|
|
342
342
|
({
|
|
343
|
-
urlFilters:
|
|
343
|
+
urlFilters: r,
|
|
344
344
|
timeouts: a
|
|
345
345
|
}) => {
|
|
346
346
|
function o(c) {
|
|
347
347
|
return function(f) {
|
|
348
348
|
let y = !1;
|
|
349
|
-
for (let
|
|
350
|
-
const w = c[
|
|
349
|
+
for (let j = 0, h = c.length; j < h; j++) {
|
|
350
|
+
const w = c[j];
|
|
351
351
|
w.pattern.test(f) && (y = w.value);
|
|
352
352
|
}
|
|
353
353
|
return y;
|
|
354
354
|
};
|
|
355
355
|
}
|
|
356
|
-
const i =
|
|
356
|
+
const i = r && o(r);
|
|
357
357
|
let u = performance.getEntries && performance.getEntries();
|
|
358
358
|
return u || (u = []), u.push({
|
|
359
359
|
name: location.href
|
|
@@ -369,18 +369,18 @@ async function Tt({
|
|
|
369
369
|
}) : null;
|
|
370
370
|
if (navigator.userAgent.indexOf("Chrome") === -1)
|
|
371
371
|
return null;
|
|
372
|
-
const
|
|
373
|
-
let
|
|
374
|
-
const
|
|
375
|
-
|
|
372
|
+
const x = typeof AbortController < "u" ? new AbortController() : null, f = new URL(c.name).origin === location.origin, y = f ? a.downloadInternal : a.downloadExternal;
|
|
373
|
+
let j;
|
|
374
|
+
const h = new Promise((l, E) => {
|
|
375
|
+
j = E;
|
|
376
376
|
}), w = y && setTimeout(() => {
|
|
377
|
-
|
|
377
|
+
x?.abort(), j(
|
|
378
378
|
new Error("[test][getPageHttpErrors] fetch timeout")
|
|
379
379
|
);
|
|
380
380
|
}, y);
|
|
381
381
|
let m = fetch(c.name, {
|
|
382
382
|
mode: f ? "same-origin" : "no-cors",
|
|
383
|
-
signal:
|
|
383
|
+
signal: x?.signal,
|
|
384
384
|
cache: f ? "force-cache" : void 0,
|
|
385
385
|
method: "HEAD"
|
|
386
386
|
}).then((l) => l.ok ? null : {
|
|
@@ -390,56 +390,56 @@ async function Tt({
|
|
|
390
390
|
url: c.name,
|
|
391
391
|
error: l.message
|
|
392
392
|
}));
|
|
393
|
-
|
|
394
|
-
function
|
|
393
|
+
x || (m = Promise.race([m, h]));
|
|
394
|
+
function T() {
|
|
395
395
|
w && clearTimeout(w);
|
|
396
396
|
}
|
|
397
397
|
return m.then(
|
|
398
|
-
(l) => (
|
|
398
|
+
(l) => (T(), l),
|
|
399
399
|
(l) => {
|
|
400
|
-
throw
|
|
400
|
+
throw T(), l;
|
|
401
401
|
}
|
|
402
402
|
);
|
|
403
403
|
}
|
|
404
404
|
)
|
|
405
405
|
).then((c) => {
|
|
406
|
-
const
|
|
406
|
+
const x = c.filter((f) => f).map(
|
|
407
407
|
(f) => ({
|
|
408
408
|
url: new URL(f.url),
|
|
409
409
|
error: f.error
|
|
410
410
|
})
|
|
411
411
|
);
|
|
412
|
-
return
|
|
412
|
+
return x.length > 0 ? x : null;
|
|
413
413
|
});
|
|
414
414
|
},
|
|
415
415
|
{
|
|
416
416
|
urlFilters: e,
|
|
417
|
-
timeouts:
|
|
417
|
+
timeouts: n
|
|
418
418
|
}
|
|
419
419
|
),
|
|
420
|
-
{ timeout:
|
|
420
|
+
{ timeout: n.total }
|
|
421
421
|
);
|
|
422
422
|
}
|
|
423
|
-
async function
|
|
423
|
+
async function Ft({
|
|
424
424
|
page: t,
|
|
425
425
|
urlFilters: e,
|
|
426
|
-
errorFilter:
|
|
426
|
+
errorFilter: n
|
|
427
427
|
}) {
|
|
428
|
-
let s = await
|
|
428
|
+
let s = await Dt({
|
|
429
429
|
page: t,
|
|
430
430
|
urlFilters: e
|
|
431
431
|
});
|
|
432
|
-
if (s && (
|
|
432
|
+
if (s && (n && (s = s.filter(n)), s.length > 0))
|
|
433
433
|
throw new Error(
|
|
434
434
|
`[test][checkPageHttpErrors] Page has http errors: ${JSON.stringify(s, null, 2)}`
|
|
435
435
|
);
|
|
436
436
|
}
|
|
437
|
-
async function
|
|
437
|
+
async function It({
|
|
438
438
|
page: t,
|
|
439
439
|
filter: e,
|
|
440
|
-
onError:
|
|
440
|
+
onError: n
|
|
441
441
|
}) {
|
|
442
|
-
const s = "callback_191b355ea6f64499a6607ad571da5d4d",
|
|
442
|
+
const s = "callback_191b355ea6f64499a6607ad571da5d4d", r = t.context().browser()?.browserType().name(), a = pt();
|
|
443
443
|
function o(i) {
|
|
444
444
|
try {
|
|
445
445
|
if (e && !e({
|
|
@@ -452,10 +452,10 @@ async function _t({
|
|
|
452
452
|
}
|
|
453
453
|
try {
|
|
454
454
|
console.error(
|
|
455
|
-
`[test][subscribeJsErrors] BROWSER JS ERROR (${
|
|
455
|
+
`[test][subscribeJsErrors] BROWSER JS ERROR (${r}): ${i}`
|
|
456
456
|
);
|
|
457
457
|
const u = new Error(i);
|
|
458
|
-
u.stack = a,
|
|
458
|
+
u.stack = a, n(u);
|
|
459
459
|
} catch (u) {
|
|
460
460
|
console.error("[test][subscribeJsErrors] error", u);
|
|
461
461
|
}
|
|
@@ -472,13 +472,13 @@ async function _t({
|
|
|
472
472
|
const y = /* @__PURE__ */ new Set();
|
|
473
473
|
return JSON.stringify(
|
|
474
474
|
f,
|
|
475
|
-
(
|
|
476
|
-
if (typeof
|
|
477
|
-
if (y.has(
|
|
475
|
+
(j, h) => {
|
|
476
|
+
if (typeof h == "object" && h != null) {
|
|
477
|
+
if (y.has(h))
|
|
478
478
|
return "[Circular]";
|
|
479
|
-
y.add(
|
|
479
|
+
y.add(h);
|
|
480
480
|
}
|
|
481
|
-
return
|
|
481
|
+
return h;
|
|
482
482
|
},
|
|
483
483
|
2
|
|
484
484
|
);
|
|
@@ -488,14 +488,14 @@ async function _t({
|
|
|
488
488
|
function c(f) {
|
|
489
489
|
window[i](f);
|
|
490
490
|
}
|
|
491
|
-
const
|
|
491
|
+
const x = {
|
|
492
492
|
warn: console.warn.bind(console),
|
|
493
493
|
error: console.error.bind(console)
|
|
494
494
|
};
|
|
495
495
|
console.warn = function(...y) {
|
|
496
|
-
return c("console.warn: " + u(y)),
|
|
496
|
+
return c("console.warn: " + u(y)), x.warn.apply(this, y);
|
|
497
497
|
}, console.error = function(...y) {
|
|
498
|
-
return c("console.error: " + u(y)),
|
|
498
|
+
return c("console.error: " + u(y)), x.error.apply(this, y);
|
|
499
499
|
}, window.addEventListener(
|
|
500
500
|
"error",
|
|
501
501
|
function(f) {
|
|
@@ -513,7 +513,7 @@ async function _t({
|
|
|
513
513
|
}
|
|
514
514
|
async function Rt() {
|
|
515
515
|
try {
|
|
516
|
-
process.platform === "win32" && await
|
|
516
|
+
process.platform === "win32" && await Mt(
|
|
517
517
|
`wmic process where "commandline like '%ms-playwright%' and not commandline like '%wmic.exe%' and priority != 4" CALL setpriority "idle"`
|
|
518
518
|
);
|
|
519
519
|
} catch (t) {
|
|
@@ -523,59 +523,59 @@ async function Rt() {
|
|
|
523
523
|
console.warn("[test][setPlaywrightPriorityLow] error: " + e);
|
|
524
524
|
}
|
|
525
525
|
}
|
|
526
|
-
let
|
|
527
|
-
function
|
|
526
|
+
let H = null, q = null;
|
|
527
|
+
function ne(t) {
|
|
528
528
|
q = t;
|
|
529
529
|
}
|
|
530
|
-
function
|
|
531
|
-
if (
|
|
530
|
+
function _t() {
|
|
531
|
+
if (H)
|
|
532
532
|
return;
|
|
533
533
|
const t = q || (process.env.DELAY_ON_ERROR ? parseInt(process.env.DELAY_ON_ERROR, 10) : 0);
|
|
534
534
|
if (q)
|
|
535
|
-
return console.log(`[test][delayOnError] Delay on error: ${t} ms`),
|
|
535
|
+
return console.log(`[test][delayOnError] Delay on error: ${t} ms`), H = at(t), H;
|
|
536
536
|
}
|
|
537
537
|
function se() {
|
|
538
|
-
return
|
|
538
|
+
return H;
|
|
539
539
|
}
|
|
540
540
|
async function Nt(t) {
|
|
541
|
-
const { page: e } = t,
|
|
541
|
+
const { page: e } = t, n = e.context().browser()?.browserType().name(), s = new St(), r = st(
|
|
542
542
|
s.signal,
|
|
543
543
|
t.abortSignal
|
|
544
544
|
), a = (i) => {
|
|
545
|
-
let u = `Error in (${
|
|
545
|
+
let u = `Error in (${n}) ${e.url()}
|
|
546
546
|
`;
|
|
547
547
|
t.pageFilePath && (u += ` at _ (${ot.resolve(t.pageFilePath)}:0:0)
|
|
548
548
|
`), i.stack = u + (i.stack || i.message), i.message = u + i.message, console.error("[test][initPage] error", i), s.abort(i);
|
|
549
549
|
};
|
|
550
|
-
return await
|
|
550
|
+
return await It({
|
|
551
551
|
page: e,
|
|
552
552
|
filter: t.filters?.js?.filter,
|
|
553
553
|
onError: a
|
|
554
554
|
}), {
|
|
555
|
-
abortSignal:
|
|
555
|
+
abortSignal: r,
|
|
556
556
|
checkErrors: async () => {
|
|
557
|
-
await
|
|
557
|
+
await Ft({
|
|
558
558
|
page: e,
|
|
559
559
|
urlFilters: t.filters?.http?.urlFilters,
|
|
560
560
|
errorFilter: t.filters?.http?.errorFilter
|
|
561
|
-
}),
|
|
561
|
+
}), r.throwIfAborted();
|
|
562
562
|
}
|
|
563
563
|
};
|
|
564
564
|
}
|
|
565
565
|
async function ae({
|
|
566
566
|
page: t,
|
|
567
567
|
abortSignal: e,
|
|
568
|
-
filters:
|
|
568
|
+
filters: n,
|
|
569
569
|
func: s,
|
|
570
|
-
pageFilePath:
|
|
570
|
+
pageFilePath: r
|
|
571
571
|
}) {
|
|
572
572
|
const a = t.context().browser()?.browserType().name();
|
|
573
573
|
try {
|
|
574
574
|
const { abortSignal: o, checkErrors: i } = await Nt({
|
|
575
575
|
page: t,
|
|
576
576
|
abortSignal: e,
|
|
577
|
-
filters:
|
|
578
|
-
pageFilePath:
|
|
577
|
+
filters: n,
|
|
578
|
+
pageFilePath: r
|
|
579
579
|
});
|
|
580
580
|
await s({
|
|
581
581
|
page: t,
|
|
@@ -585,7 +585,7 @@ async function ae({
|
|
|
585
585
|
} catch (o) {
|
|
586
586
|
let i = `Error in (${a}) ${t.url()}
|
|
587
587
|
`;
|
|
588
|
-
throw
|
|
588
|
+
throw r && (i += ` at _ (${ot.resolve(r)}:0:0)
|
|
589
589
|
`), o.stack = i + (o.stack || o.message), o.message = i + o.message, o;
|
|
590
590
|
}
|
|
591
591
|
}
|
|
@@ -594,11 +594,11 @@ function oe({
|
|
|
594
594
|
options: e
|
|
595
595
|
}) {
|
|
596
596
|
return async function(s) {
|
|
597
|
-
const
|
|
597
|
+
const r = await t.launch(e ?? void 0);
|
|
598
598
|
try {
|
|
599
|
-
return await s(
|
|
599
|
+
return await s(r);
|
|
600
600
|
} finally {
|
|
601
|
-
await
|
|
601
|
+
await r.close();
|
|
602
602
|
}
|
|
603
603
|
};
|
|
604
604
|
}
|
|
@@ -607,70 +607,70 @@ function ie({
|
|
|
607
607
|
options: e
|
|
608
608
|
}) {
|
|
609
609
|
return async function(s) {
|
|
610
|
-
const
|
|
610
|
+
const r = await t.newContext(e ?? void 0);
|
|
611
611
|
await Rt();
|
|
612
612
|
try {
|
|
613
|
-
const a = await s(
|
|
614
|
-
return await
|
|
613
|
+
const a = await s(r);
|
|
614
|
+
return await r.close(), a;
|
|
615
615
|
} catch (a) {
|
|
616
|
-
const o =
|
|
617
|
-
throw o ? (console.error("[test][useBrowserContext] error", a), o.finally(() =>
|
|
616
|
+
const o = _t?.();
|
|
617
|
+
throw o ? (console.error("[test][useBrowserContext] error", a), o.finally(() => r.close())) : await r.close(), a;
|
|
618
618
|
}
|
|
619
619
|
};
|
|
620
620
|
}
|
|
621
621
|
async function Y(t, e) {
|
|
622
|
-
const
|
|
623
|
-
await
|
|
622
|
+
const n = D.dirname(t);
|
|
623
|
+
await F.promises.stat(n).catch(() => null) || await F.promises.mkdir(n, { recursive: !0 }), await F.promises.writeFile(t, JSON.stringify(e, null, 4), {
|
|
624
624
|
encoding: "utf-8"
|
|
625
625
|
});
|
|
626
626
|
}
|
|
627
|
-
async function
|
|
628
|
-
if (!await
|
|
627
|
+
async function Wt(t) {
|
|
628
|
+
if (!await F.promises.stat(t).catch(() => null))
|
|
629
629
|
return null;
|
|
630
|
-
const e = await
|
|
630
|
+
const e = await F.promises.readFile(t, { encoding: "utf-8" });
|
|
631
631
|
return JSON.parse(e);
|
|
632
632
|
}
|
|
633
|
-
const
|
|
634
|
-
function
|
|
633
|
+
const X = "-", Q = "+";
|
|
634
|
+
function G(t, e, n) {
|
|
635
635
|
if (t === e)
|
|
636
636
|
return null;
|
|
637
637
|
if (Array.isArray(t)) {
|
|
638
638
|
if (Array.isArray(e)) {
|
|
639
|
-
let
|
|
639
|
+
let r = null;
|
|
640
640
|
for (let a = 0, o = Math.max(e.length, e.length); a < o; a++) {
|
|
641
|
-
const i =
|
|
642
|
-
i != null && (
|
|
641
|
+
const i = G(t[a], e[a], n);
|
|
642
|
+
i != null && (r || (r = []), r.push(i));
|
|
643
643
|
}
|
|
644
|
-
return
|
|
644
|
+
return r != null && n && (r = n(t, e, r)), r;
|
|
645
645
|
}
|
|
646
646
|
} else if (t instanceof Object && e instanceof Object) {
|
|
647
|
-
let
|
|
647
|
+
let r = null;
|
|
648
648
|
for (const a in t)
|
|
649
649
|
if (Object.prototype.hasOwnProperty.call(t, a)) {
|
|
650
|
-
const o =
|
|
651
|
-
o != null && (
|
|
650
|
+
const o = G(t[a], e[a], n);
|
|
651
|
+
o != null && (r || (r = {}), r[a] = o);
|
|
652
652
|
}
|
|
653
653
|
for (const a in e)
|
|
654
654
|
if (Object.prototype.hasOwnProperty.call(e, a) && !Object.prototype.hasOwnProperty.call(t, a)) {
|
|
655
|
-
const o =
|
|
656
|
-
o != null && (
|
|
655
|
+
const o = G(t[a], e[a], n);
|
|
656
|
+
o != null && (r || (r = {}), r[a] = o);
|
|
657
657
|
}
|
|
658
|
-
return
|
|
658
|
+
return r != null && n && (r = n(t, e, r)), r;
|
|
659
659
|
}
|
|
660
660
|
let s = {
|
|
661
|
-
[
|
|
662
|
-
[
|
|
661
|
+
[X]: t,
|
|
662
|
+
[Q]: e
|
|
663
663
|
};
|
|
664
|
-
return
|
|
664
|
+
return n && (s = n(t, e, s)), s;
|
|
665
665
|
}
|
|
666
|
-
function
|
|
666
|
+
function nt(t) {
|
|
667
667
|
function e(l) {
|
|
668
|
-
return l.sort((
|
|
668
|
+
return l.sort((E, S) => E[0] > S[0] ? 1 : -1).reduce((E, S) => (E[S[0]] = S[1], E), {});
|
|
669
669
|
}
|
|
670
|
-
function
|
|
671
|
-
return l.reduce((
|
|
670
|
+
function n(l) {
|
|
671
|
+
return l.reduce((E, S) => (E[S] = !0, E), {});
|
|
672
672
|
}
|
|
673
|
-
const s = t.filters && t.filters.excludeAttrs &&
|
|
673
|
+
const s = t.filters && t.filters.excludeAttrs && n(t.filters.excludeAttrs), r = t.filters && t.filters.fixAttrs, a = t.filters && t.filters.fixStyles, o = t.filters && t.filters.excludeStyles && n(t.filters.excludeStyles), i = t.filters && t.filters.fixTags, u = t.filters && t.filters.excludeClasses, c = t.filters && t.filters.excludeIds, x = t.filters && t.filters.excludeSelectorClasses, f = t.filters && t.filters.excludeSelectorIds;
|
|
674
674
|
let y;
|
|
675
675
|
if (t.filters && t.filters.excludeSelectors && t.filters.excludeSelectors.length > 0) {
|
|
676
676
|
const l = Array.from(
|
|
@@ -678,111 +678,111 @@ function rt(t) {
|
|
|
678
678
|
);
|
|
679
679
|
l.length > 0 && (y = new Set(l));
|
|
680
680
|
}
|
|
681
|
-
function
|
|
682
|
-
const O = getComputedStyle(l,
|
|
683
|
-
for (let
|
|
684
|
-
const
|
|
685
|
-
if (o && o[
|
|
681
|
+
function j(l, E, S, g) {
|
|
682
|
+
const O = getComputedStyle(l, E), p = [];
|
|
683
|
+
for (let b = 0, k = O.length; b < k; b++) {
|
|
684
|
+
const P = O[b];
|
|
685
|
+
if (o && o[P])
|
|
686
686
|
continue;
|
|
687
|
-
let
|
|
688
|
-
if (
|
|
689
|
-
for (let A = 0,
|
|
690
|
-
a[A].name.test(
|
|
691
|
-
(!
|
|
687
|
+
let d = O[P];
|
|
688
|
+
if (d && a)
|
|
689
|
+
for (let A = 0, C = a.length; A < C; A++)
|
|
690
|
+
a[A].name.test(P) && (d = d.replace(a[A].search, a[A].replace));
|
|
691
|
+
(!S || S[P] !== d) && (!g || g[P] === d) && p.push([P, d]);
|
|
692
692
|
}
|
|
693
693
|
return e(p);
|
|
694
694
|
}
|
|
695
|
-
function
|
|
695
|
+
function h(l, E, S) {
|
|
696
696
|
return {
|
|
697
|
-
_:
|
|
697
|
+
_: j(
|
|
698
698
|
l,
|
|
699
699
|
void 0,
|
|
700
|
-
|
|
701
|
-
|
|
700
|
+
E && E._,
|
|
701
|
+
S && S._
|
|
702
702
|
),
|
|
703
|
-
before:
|
|
703
|
+
before: j(
|
|
704
704
|
l,
|
|
705
705
|
"before",
|
|
706
|
-
|
|
707
|
-
|
|
706
|
+
E && E.before,
|
|
707
|
+
S && S.before
|
|
708
708
|
),
|
|
709
|
-
after:
|
|
709
|
+
after: j(
|
|
710
710
|
l,
|
|
711
711
|
"after",
|
|
712
|
-
|
|
713
|
-
|
|
712
|
+
E && E.after,
|
|
713
|
+
S && S.after
|
|
714
714
|
)
|
|
715
715
|
};
|
|
716
716
|
}
|
|
717
|
-
function w(l,
|
|
718
|
-
for (let p = 0,
|
|
717
|
+
function w(l, E, S, g, O) {
|
|
718
|
+
for (let p = 0, b = l.childNodes.length; p < b; p++) {
|
|
719
719
|
const k = l.childNodes[p];
|
|
720
720
|
if (!k)
|
|
721
721
|
throw new Error(
|
|
722
|
-
`child is null; index=${p}; ${
|
|
722
|
+
`child is null; index=${p}; ${g}, ${l.className}\r
|
|
723
723
|
You should wait js executions before test`
|
|
724
724
|
);
|
|
725
725
|
k instanceof Element && m(
|
|
726
726
|
k,
|
|
727
|
+
E,
|
|
727
728
|
S,
|
|
728
|
-
|
|
729
|
-
x,
|
|
729
|
+
g,
|
|
730
730
|
O
|
|
731
731
|
);
|
|
732
732
|
}
|
|
733
733
|
}
|
|
734
|
-
function m(l,
|
|
735
|
-
const p = O && O[
|
|
734
|
+
function m(l, E, S, g, O) {
|
|
735
|
+
const p = O && O[E.length];
|
|
736
736
|
if (O && !p || y && y.has(l))
|
|
737
737
|
return;
|
|
738
|
-
let
|
|
739
|
-
if (
|
|
740
|
-
for (let L = 0,
|
|
741
|
-
|
|
742
|
-
if (p && p.tag !==
|
|
738
|
+
let b = l.tagName && l.tagName.toLowerCase();
|
|
739
|
+
if (b === "head" && (S = !1), i)
|
|
740
|
+
for (let L = 0, $ = i.length; L < $; L++)
|
|
741
|
+
b = b.replace(i[L].search, i[L].replace);
|
|
742
|
+
if (p && p.tag !== b)
|
|
743
743
|
return;
|
|
744
744
|
const k = [];
|
|
745
|
-
for (let L = 0,
|
|
745
|
+
for (let L = 0, $ = l.attributes.length; L < $; L++) {
|
|
746
746
|
const R = l.attributes.item(L);
|
|
747
|
-
let
|
|
748
|
-
if (
|
|
749
|
-
if (
|
|
750
|
-
for (let B = 0,
|
|
751
|
-
|
|
752
|
-
(!p || p.attrs && p.attrs[
|
|
747
|
+
let _ = R.name, J = R.value;
|
|
748
|
+
if (_ = _.toLowerCase(), _ !== "class" && !(s && s[_])) {
|
|
749
|
+
if (r)
|
|
750
|
+
for (let B = 0, dt = r.length; B < dt; B++)
|
|
751
|
+
r[B].name.test(_) && (J = J.replace(r[B].search, r[B].replace));
|
|
752
|
+
(!p || p.attrs && p.attrs[_] === J) && k.push([_, J]);
|
|
753
753
|
}
|
|
754
754
|
}
|
|
755
|
-
const
|
|
756
|
-
for (let L = 0,
|
|
755
|
+
const P = [], d = [];
|
|
756
|
+
for (let L = 0, $ = l.classList.length; L < $; L++) {
|
|
757
757
|
const R = l.classList.item(L);
|
|
758
|
-
(!u || !u.test(R)) &&
|
|
758
|
+
(!u || !u.test(R)) && P.push(R), (!x || !x.test(R)) && d.push(R);
|
|
759
759
|
}
|
|
760
|
-
const A =
|
|
760
|
+
const A = S ? h(l, t.defaultStyle, p && p.style) : null, C = l.childElementCount ? [] : null;
|
|
761
761
|
l.id && (!c || !c.test(l.id)) && l.id;
|
|
762
|
-
const
|
|
763
|
-
tag:
|
|
762
|
+
const M = l.id && (!f || !f.test(l.id)) ? l.id : "", I = (b || "") + (M ? "#" + M : "") + (d.length > 0 ? "." + d.join(".") : ""), tt = I ? g ? g + " > " + I : I : g, ht = {
|
|
763
|
+
tag: b,
|
|
764
764
|
selector: tt,
|
|
765
|
-
classes:
|
|
765
|
+
classes: P,
|
|
766
766
|
attrs: k.length > 0 ? e(k) : null,
|
|
767
767
|
style: A,
|
|
768
|
-
childs:
|
|
768
|
+
childs: C
|
|
769
769
|
};
|
|
770
|
-
|
|
770
|
+
E.push(ht), C && w(
|
|
771
771
|
l,
|
|
772
|
-
|
|
773
|
-
|
|
772
|
+
C,
|
|
773
|
+
S,
|
|
774
774
|
tt,
|
|
775
775
|
p && p.childs
|
|
776
776
|
);
|
|
777
777
|
}
|
|
778
|
-
const
|
|
778
|
+
const T = [];
|
|
779
779
|
return m(
|
|
780
780
|
document.documentElement,
|
|
781
|
-
|
|
781
|
+
T,
|
|
782
782
|
!0,
|
|
783
783
|
"",
|
|
784
784
|
t.shouldEqualResult && [t.shouldEqualResult]
|
|
785
|
-
),
|
|
785
|
+
), T[0];
|
|
786
786
|
}
|
|
787
787
|
async function ct(t) {
|
|
788
788
|
const e = await t.context().newCDPSession(t);
|
|
@@ -792,42 +792,42 @@ async function lt(t) {
|
|
|
792
792
|
await t.send("CSS.disable"), await t.send("DOM.disable"), await t.detach();
|
|
793
793
|
}
|
|
794
794
|
async function ce(t, e) {
|
|
795
|
-
const
|
|
795
|
+
const n = await ct(t);
|
|
796
796
|
try {
|
|
797
|
-
return await e(
|
|
797
|
+
return await e(n);
|
|
798
798
|
} finally {
|
|
799
|
-
await lt(
|
|
799
|
+
await lt(n);
|
|
800
800
|
}
|
|
801
801
|
}
|
|
802
|
-
async function
|
|
803
|
-
const { nodes:
|
|
802
|
+
async function $t(t, e) {
|
|
803
|
+
const { nodes: n } = await t.send("DOM.getFlattenedDocument", {
|
|
804
804
|
depth: -1,
|
|
805
805
|
pierce: !0
|
|
806
|
-
}), s =
|
|
807
|
-
for (const
|
|
806
|
+
}), s = n.filter((r) => r.nodeType === 1).map((r) => r.nodeId);
|
|
807
|
+
for (const r of s)
|
|
808
808
|
await t.send("CSS.forcePseudoState", {
|
|
809
|
-
nodeId:
|
|
809
|
+
nodeId: r,
|
|
810
810
|
forcedPseudoClasses: e
|
|
811
811
|
});
|
|
812
812
|
}
|
|
813
813
|
function K(t, e) {
|
|
814
814
|
if (!t || !e)
|
|
815
815
|
return e || null;
|
|
816
|
-
let
|
|
816
|
+
let n = null;
|
|
817
817
|
for (const s in e)
|
|
818
|
-
Object.prototype.hasOwnProperty.call(e, s) && e[s] !== t[s] && (
|
|
818
|
+
Object.prototype.hasOwnProperty.call(e, s) && e[s] !== t[s] && (n || (n = {}), n[s] = e[s]);
|
|
819
819
|
for (const s in t)
|
|
820
|
-
Object.prototype.hasOwnProperty.call(t, s) && !Object.prototype.hasOwnProperty.call(e, s) && (
|
|
821
|
-
return
|
|
820
|
+
Object.prototype.hasOwnProperty.call(t, s) && !Object.prototype.hasOwnProperty.call(e, s) && (n || (n = {}), n[s] = "");
|
|
821
|
+
return n;
|
|
822
822
|
}
|
|
823
823
|
function Bt(t, e) {
|
|
824
824
|
if (!t || !e)
|
|
825
825
|
return e || null;
|
|
826
|
-
const
|
|
827
|
-
return !
|
|
828
|
-
_:
|
|
826
|
+
const n = K(t._, e._), s = K(t.before, e.before), r = K(t.after, e.after);
|
|
827
|
+
return !n && !s && !r ? null : {
|
|
828
|
+
_: n || {},
|
|
829
829
|
before: s || {},
|
|
830
|
-
after:
|
|
830
|
+
after: r || {}
|
|
831
831
|
};
|
|
832
832
|
}
|
|
833
833
|
function zt(t, e) {
|
|
@@ -835,13 +835,13 @@ function zt(t, e) {
|
|
|
835
835
|
return e || null;
|
|
836
836
|
if (t.length !== e.length)
|
|
837
837
|
return e;
|
|
838
|
-
for (let
|
|
839
|
-
if (t[
|
|
838
|
+
for (let n = 0, s = t.length; n < s; n++)
|
|
839
|
+
if (t[n] !== e[n])
|
|
840
840
|
return e;
|
|
841
841
|
return null;
|
|
842
842
|
}
|
|
843
843
|
function ut(t, e) {
|
|
844
|
-
const
|
|
844
|
+
const n = zt(t.classes, e.classes), s = K(t.attrs, e.attrs), r = Bt(t.style, e.style);
|
|
845
845
|
let a = null;
|
|
846
846
|
if (t.childs && e.childs) {
|
|
847
847
|
const o = Math.min(t.childs.length, e.childs.length);
|
|
@@ -857,57 +857,57 @@ function ut(t, e) {
|
|
|
857
857
|
}
|
|
858
858
|
}
|
|
859
859
|
}
|
|
860
|
-
return !
|
|
860
|
+
return !n && !s && !r && !a ? null : {
|
|
861
861
|
tag: e.tag,
|
|
862
862
|
selector: e.selector,
|
|
863
|
-
classes:
|
|
863
|
+
classes: n,
|
|
864
864
|
attrs: s,
|
|
865
|
-
style:
|
|
865
|
+
style: r,
|
|
866
866
|
childs: a
|
|
867
867
|
};
|
|
868
868
|
}
|
|
869
|
-
const V = (t, e,
|
|
870
|
-
const
|
|
871
|
-
if (
|
|
872
|
-
return
|
|
873
|
-
if (Array.isArray(
|
|
874
|
-
return
|
|
869
|
+
const V = (t, e, n, s) => {
|
|
870
|
+
const r = s(t, e, n, s);
|
|
871
|
+
if (r == null)
|
|
872
|
+
return r;
|
|
873
|
+
if (Array.isArray(r))
|
|
874
|
+
return r.map(
|
|
875
875
|
(a, o, i) => V(a, o, i, s)
|
|
876
876
|
);
|
|
877
|
-
if (typeof
|
|
877
|
+
if (typeof r == "object") {
|
|
878
878
|
const a = {};
|
|
879
|
-
for (const o in
|
|
880
|
-
Object.prototype.hasOwnProperty.call(
|
|
879
|
+
for (const o in r)
|
|
880
|
+
Object.prototype.hasOwnProperty.call(r, o) && (a[o] = V(r[o], o, r, s));
|
|
881
881
|
return a;
|
|
882
882
|
}
|
|
883
|
-
return
|
|
883
|
+
return r;
|
|
884
884
|
};
|
|
885
885
|
function ft(t, e) {
|
|
886
886
|
if (t.attrs && e.excludeAttrs) {
|
|
887
|
-
for (let
|
|
888
|
-
delete t.attrs[e.excludeAttrs[
|
|
887
|
+
for (let n = 0, s = e.excludeAttrs.length; n < s; n++)
|
|
888
|
+
delete t.attrs[e.excludeAttrs[n]];
|
|
889
889
|
Object.keys(t.attrs).length === 0 && (t.attrs = null);
|
|
890
890
|
}
|
|
891
891
|
if (t.classes && e.excludeClasses && (t.classes = t.classes.filter(
|
|
892
|
-
(
|
|
892
|
+
(n) => !e.excludeClasses.test(n)
|
|
893
893
|
)), t.style && e.excludeStyles)
|
|
894
|
-
for (const
|
|
895
|
-
const s = t.style[
|
|
894
|
+
for (const n of ["_", "before", "after"]) {
|
|
895
|
+
const s = t.style[n];
|
|
896
896
|
if (s)
|
|
897
|
-
for (let
|
|
898
|
-
delete s[e.excludeStyles[
|
|
897
|
+
for (let r = 0, a = e.excludeStyles.length; r < a; r++)
|
|
898
|
+
delete s[e.excludeStyles[r]];
|
|
899
899
|
}
|
|
900
900
|
if (t.childs)
|
|
901
|
-
for (let
|
|
902
|
-
ft(t.childs[
|
|
901
|
+
for (let n = 0, s = t.childs.length; n < s; n++)
|
|
902
|
+
ft(t.childs[n], e);
|
|
903
903
|
}
|
|
904
904
|
function Jt(t, e) {
|
|
905
|
-
for (const
|
|
906
|
-
if (!Object.prototype.hasOwnProperty.call(t,
|
|
907
|
-
const s = t[
|
|
908
|
-
for (const
|
|
909
|
-
if (!Object.prototype.hasOwnProperty.call(s,
|
|
910
|
-
const a = s[
|
|
905
|
+
for (const n in t) {
|
|
906
|
+
if (!Object.prototype.hasOwnProperty.call(t, n)) continue;
|
|
907
|
+
const s = t[n];
|
|
908
|
+
for (const r in s) {
|
|
909
|
+
if (!Object.prototype.hasOwnProperty.call(s, r)) continue;
|
|
910
|
+
const a = s[r];
|
|
911
911
|
for (const o in a)
|
|
912
912
|
Object.prototype.hasOwnProperty.call(a, o) && ft(a[o], e);
|
|
913
913
|
}
|
|
@@ -916,83 +916,83 @@ function Jt(t, e) {
|
|
|
916
916
|
function le({
|
|
917
917
|
actualResultFile: t,
|
|
918
918
|
expectedResultFile: e,
|
|
919
|
-
diffResultFile:
|
|
919
|
+
diffResultFile: n,
|
|
920
920
|
filters: s,
|
|
921
|
-
transform:
|
|
921
|
+
transform: r,
|
|
922
922
|
pseudoStates: a
|
|
923
923
|
}) {
|
|
924
924
|
let o, i, u, c = {};
|
|
925
925
|
return {
|
|
926
|
-
async init(
|
|
927
|
-
o = await
|
|
926
|
+
async init(x) {
|
|
927
|
+
o = await Wt(e), r && (o = V(o, null, null, r)), o && s && Jt(o, s), await x.goto("about:blank"), i = await x.evaluate(nt, { filters: s }), u = i.style;
|
|
928
928
|
},
|
|
929
929
|
async handlePage({
|
|
930
|
-
page:
|
|
930
|
+
page: x,
|
|
931
931
|
testId: f,
|
|
932
932
|
url: y,
|
|
933
|
-
stateId:
|
|
934
|
-
_filters:
|
|
933
|
+
stateId: j,
|
|
934
|
+
_filters: h
|
|
935
935
|
}) {
|
|
936
936
|
let w = c[f];
|
|
937
937
|
w || (w = {}, c[f] = w);
|
|
938
938
|
let m = w[y.href];
|
|
939
|
-
m || (m = {}, w[y.href] = m), await
|
|
939
|
+
m || (m = {}, w[y.href] = m), await x.addStyleTag({
|
|
940
940
|
content: "*, *::before, *::after { animation-name: none!important; transition-duration: 0s !important; }"
|
|
941
941
|
});
|
|
942
|
-
const
|
|
943
|
-
let l = null,
|
|
942
|
+
const T = a ?? [{ states: [] }];
|
|
943
|
+
let l = null, E;
|
|
944
944
|
try {
|
|
945
|
-
for (let
|
|
946
|
-
const
|
|
945
|
+
for (let S = 0; S < T.length; S++) {
|
|
946
|
+
const g = T[S], O = g.states.length > 0 ? j + ":" + g.states.join(":") : j;
|
|
947
947
|
let p = null;
|
|
948
|
-
if (
|
|
949
|
-
l || (l = await ct(
|
|
950
|
-
const
|
|
951
|
-
await
|
|
948
|
+
if (g.states.length > 0) {
|
|
949
|
+
l || (l = await ct(x));
|
|
950
|
+
const d = performance.now();
|
|
951
|
+
await $t(l, g.states), p = performance.now() - d;
|
|
952
952
|
}
|
|
953
|
-
|
|
954
|
-
const
|
|
955
|
-
filters:
|
|
953
|
+
g.delay && await at(g.delay);
|
|
954
|
+
const b = performance.now(), k = await x.evaluate(nt, {
|
|
955
|
+
filters: h || s,
|
|
956
956
|
defaultStyle: u,
|
|
957
957
|
shouldEqualResult: m[O]
|
|
958
|
-
}),
|
|
958
|
+
}), P = performance.now() - b;
|
|
959
959
|
if (console.log(
|
|
960
|
-
`SNAPSHOT ${O}:` + (p != null ? ` forcePseudoClasses ${p.toFixed(0)}ms,` : "") + ` getAllElements ${
|
|
961
|
-
), !
|
|
962
|
-
|
|
960
|
+
`SNAPSHOT ${O}:` + (p != null ? ` forcePseudoClasses ${p.toFixed(0)}ms,` : "") + ` getAllElements ${P.toFixed(0)}ms`
|
|
961
|
+
), !E)
|
|
962
|
+
E = k, m[O] = k;
|
|
963
963
|
else {
|
|
964
|
-
const
|
|
965
|
-
|
|
964
|
+
const d = ut(E, k);
|
|
965
|
+
d && (m[O] = d);
|
|
966
966
|
}
|
|
967
967
|
}
|
|
968
968
|
} finally {
|
|
969
969
|
l && await lt(l);
|
|
970
970
|
}
|
|
971
971
|
},
|
|
972
|
-
async end({ checkExistUrlsOnly:
|
|
973
|
-
if (c = yt(c),
|
|
972
|
+
async end({ checkExistUrlsOnly: x }) {
|
|
973
|
+
if (c = yt(c), r && (c = V(c, null, null, r)), o) {
|
|
974
974
|
let f, y;
|
|
975
|
-
if (!
|
|
975
|
+
if (!x)
|
|
976
976
|
f = o, y = c;
|
|
977
977
|
else {
|
|
978
978
|
f = {}, y = {};
|
|
979
|
-
for (const
|
|
980
|
-
if (Object.prototype.hasOwnProperty.call(o,
|
|
981
|
-
f[
|
|
982
|
-
for (const w in o[
|
|
983
|
-
Object.prototype.hasOwnProperty.call(o[
|
|
979
|
+
for (const h in o)
|
|
980
|
+
if (Object.prototype.hasOwnProperty.call(o, h) && Object.prototype.hasOwnProperty.call(c, h)) {
|
|
981
|
+
f[h] = {}, y[h] = {};
|
|
982
|
+
for (const w in o[h])
|
|
983
|
+
Object.prototype.hasOwnProperty.call(o[h], w) && Object.prototype.hasOwnProperty.call(c[h], w) && (f[h][w] = o[h][w], y[h][w] = c[h][w]);
|
|
984
984
|
}
|
|
985
985
|
}
|
|
986
|
-
const
|
|
986
|
+
const j = G(
|
|
987
987
|
f,
|
|
988
988
|
y,
|
|
989
|
-
(
|
|
989
|
+
(h, w, m) => m.selector && (delete m.selector, Object.keys(m).length === 0) ? null : m.childs && m.childs.length === 1 ? m.childs[0] : (w && w.selector ? m[Q] ? m[Q] = w.selector : m = { selector: w.selector, ...m } : h && h.selector && (m[X] ? m[X] = h.selector : m = { selector: h.selector, ...m }), m)
|
|
990
990
|
);
|
|
991
|
-
if (
|
|
991
|
+
if (n && await Y(n, j || {}), j)
|
|
992
992
|
throw await Y(t, c), console.error(
|
|
993
|
-
"Pages elements changes: " + JSON.stringify(
|
|
993
|
+
"Pages elements changes: " + JSON.stringify(j, null, 4).substring(0, 5e3)
|
|
994
994
|
), new Error("Pages elements changes detected");
|
|
995
|
-
await
|
|
995
|
+
await F.promises.stat(t).catch(() => null) && await F.promises.unlink(t);
|
|
996
996
|
} else
|
|
997
997
|
await Y(e, c);
|
|
998
998
|
return c;
|
|
@@ -1000,157 +1000,190 @@ function le({
|
|
|
1000
1000
|
};
|
|
1001
1001
|
}
|
|
1002
1002
|
export {
|
|
1003
|
+
he as CheckError,
|
|
1003
1004
|
de as ConsoleMessageLevel,
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
ge as
|
|
1012
|
-
xe as
|
|
1013
|
-
Ee as
|
|
1014
|
-
Se as
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
Pe as
|
|
1020
|
-
|
|
1005
|
+
Q as DIFF_NEW,
|
|
1006
|
+
X as DIFF_OLD,
|
|
1007
|
+
me as Lazy,
|
|
1008
|
+
pe as LazyWithId,
|
|
1009
|
+
ye as LogLevel,
|
|
1010
|
+
we as MAX_REPORT_ITEMS_DEFAULT,
|
|
1011
|
+
be as MatchInternalError,
|
|
1012
|
+
ge as Matcher,
|
|
1013
|
+
xe as MatcherAny,
|
|
1014
|
+
Ee as MatcherArray,
|
|
1015
|
+
Se as MatcherArrayItem,
|
|
1016
|
+
ke as MatcherConvert,
|
|
1017
|
+
Oe as MatcherCustom,
|
|
1018
|
+
je as MatcherFew,
|
|
1019
|
+
Ce as MatcherIn,
|
|
1020
|
+
Pe as MatcherInstanceOf,
|
|
1021
|
+
Ae as MatcherIs,
|
|
1022
|
+
Le as MatcherNever,
|
|
1023
|
+
Te as MatcherNot,
|
|
1024
|
+
Me as MatcherNumber,
|
|
1025
|
+
De as MatcherObject,
|
|
1026
|
+
Fe as MatcherObjectEntry,
|
|
1027
|
+
Ie as MatcherRef,
|
|
1028
|
+
Re as MatcherString,
|
|
1029
|
+
_e as Random,
|
|
1030
|
+
Ne as Subject,
|
|
1031
|
+
We as SubjectWithId,
|
|
1032
|
+
$e as UNIQUE_PSEUDO_RANDOM_MAX_COUNT,
|
|
1033
|
+
Be as alertConsole,
|
|
1034
|
+
ze as alertReplace,
|
|
1035
|
+
Je as argsToString,
|
|
1036
|
+
Ue as check,
|
|
1037
|
+
ve as checkFunc,
|
|
1038
|
+
Ft as checkPageHttpErrors,
|
|
1039
|
+
He as consoleIntercept,
|
|
1040
|
+
Ge as consoleMessageToString,
|
|
1041
|
+
Ke as consoleReplace,
|
|
1042
|
+
Ve as convertTimeZone,
|
|
1021
1043
|
ct as createCDPSession,
|
|
1022
1044
|
te as createMatchPath,
|
|
1045
|
+
Ye as createMatchResult,
|
|
1046
|
+
qe as createMatchResultBoolean,
|
|
1047
|
+
Xe as createMatchResultError,
|
|
1023
1048
|
le as createPagesElementsChangesTest,
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1049
|
+
Qe as createTaskDelayRetry,
|
|
1050
|
+
Ze as createUniquePseudoRandom,
|
|
1051
|
+
tr as dateNowUnique,
|
|
1052
|
+
er as deepCloneJsonLike,
|
|
1053
|
+
rr as deepEqualJsonLike,
|
|
1054
|
+
nr as deepEqualJsonLikeMap,
|
|
1055
|
+
_t as delayOnErrorCall,
|
|
1056
|
+
ne as delayOnErrorSet,
|
|
1032
1057
|
se as delayOnErrorWait,
|
|
1033
1058
|
lt as destroyCDPSession,
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1059
|
+
sr as equalArray,
|
|
1060
|
+
ar as escapeHtml,
|
|
1061
|
+
or as escapeRegExp,
|
|
1062
|
+
Mt as exec,
|
|
1063
|
+
ir as expectedToString,
|
|
1064
|
+
Qt as fileLock,
|
|
1065
|
+
cr as filterMatchResult,
|
|
1066
|
+
lr as filterMatchResultNested,
|
|
1067
|
+
ur as fixStackTrace,
|
|
1068
|
+
$t as forcePseudoClasses,
|
|
1069
|
+
fr as formatAny,
|
|
1070
|
+
hr as formatDate,
|
|
1071
|
+
dr as formatDateFileName,
|
|
1072
|
+
nt as getAllElements,
|
|
1073
|
+
mr as getConsoleMessages,
|
|
1074
|
+
pr as getDateInet,
|
|
1047
1075
|
Ot as getDrive,
|
|
1048
1076
|
ut as getElementsStyleDiff,
|
|
1049
|
-
|
|
1077
|
+
jt as getFileId,
|
|
1050
1078
|
yt as getNormalizedObject,
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1079
|
+
yr as getObjectId,
|
|
1080
|
+
G as getObjectsDiff,
|
|
1081
|
+
Dt as getPageHttpErrors,
|
|
1082
|
+
wr as getRandomFunc,
|
|
1083
|
+
br as getRandomSeed,
|
|
1055
1084
|
pt as getStackTrace,
|
|
1056
1085
|
At as globGitIgnoreToPicomatch,
|
|
1057
1086
|
Lt as globToRelative,
|
|
1058
1087
|
Nt as initPage,
|
|
1059
|
-
|
|
1088
|
+
gr as isMatcher,
|
|
1089
|
+
xr as isObservable,
|
|
1060
1090
|
ee as loadGlobs,
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1091
|
+
Tt as loadGlobsFromFile,
|
|
1092
|
+
Wt as loadJson,
|
|
1093
|
+
Er as match,
|
|
1094
|
+
Sr as matchAnd,
|
|
1095
|
+
kr as matchAndPipe,
|
|
1096
|
+
Or as matchAny,
|
|
1097
|
+
jr as matchArray,
|
|
1098
|
+
Cr as matchArrayBuffer,
|
|
1099
|
+
Pr as matchArrayIncludes,
|
|
1100
|
+
Ar as matchArrayItem,
|
|
1101
|
+
Lr as matchArrayLength,
|
|
1102
|
+
Tr as matchArrayWith,
|
|
1103
|
+
Mr as matchBoolean,
|
|
1104
|
+
Dr as matchConstructor,
|
|
1105
|
+
Fr as matchConvert,
|
|
1106
|
+
Ir as matchCustom,
|
|
1107
|
+
Rr as matchDeep,
|
|
1108
|
+
_r as matchEnum,
|
|
1109
|
+
Nr as matchFloat,
|
|
1110
|
+
Wr as matchIn,
|
|
1111
|
+
$r as matchInstanceOf,
|
|
1112
|
+
Br as matchInt,
|
|
1113
|
+
zr as matchIntDate,
|
|
1114
|
+
Jr as matchIs,
|
|
1115
|
+
Ur as matchIsNonStrict,
|
|
1116
|
+
vr as matchNever,
|
|
1117
|
+
Hr as matchNot,
|
|
1118
|
+
Gr as matchNotNullish,
|
|
1119
|
+
Kr as matchNullish,
|
|
1120
|
+
Vr as matchNumber,
|
|
1121
|
+
Yr as matchObject,
|
|
1122
|
+
qr as matchObjectEntries,
|
|
1123
|
+
Xr as matchObjectEntry,
|
|
1124
|
+
Qr as matchObjectKey,
|
|
1125
|
+
Zr as matchObjectKeyValue,
|
|
1126
|
+
tn as matchObjectKeys,
|
|
1127
|
+
en as matchObjectKeysNotNull,
|
|
1128
|
+
rn as matchObjectPartial,
|
|
1129
|
+
nn as matchObjectValue,
|
|
1130
|
+
sn as matchObjectValues,
|
|
1131
|
+
an as matchObjectWith,
|
|
1132
|
+
on as matchOptional,
|
|
1133
|
+
cn as matchOr,
|
|
1134
|
+
ln as matchOrPipe,
|
|
1135
|
+
un as matchRange,
|
|
1136
|
+
fn as matchRangeDate,
|
|
1137
|
+
hn as matchRef,
|
|
1138
|
+
dn as matchResultNestedToString,
|
|
1139
|
+
mn as matchResultToString,
|
|
1140
|
+
pn as matchString,
|
|
1141
|
+
yn as matchStringLength,
|
|
1142
|
+
wn as matchTypeOf,
|
|
1143
|
+
bn as matchUuid,
|
|
1144
|
+
gn as matchValueState,
|
|
1145
|
+
xn as max,
|
|
1146
|
+
En as min,
|
|
1147
|
+
Sn as minMax,
|
|
1148
|
+
re as nodeBeep,
|
|
1149
|
+
kn as numberMod,
|
|
1118
1150
|
V as objectTransform,
|
|
1119
|
-
|
|
1120
|
-
|
|
1151
|
+
W as pathNormalize,
|
|
1152
|
+
Ct as pathResolve,
|
|
1121
1153
|
Z as poolFs,
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1154
|
+
On as randomBoolean,
|
|
1155
|
+
jn as randomEnum,
|
|
1156
|
+
Cn as randomFloat,
|
|
1157
|
+
Pn as randomIndexWeighted,
|
|
1158
|
+
An as randomInt,
|
|
1159
|
+
Ln as randomItem,
|
|
1160
|
+
Tn as randomItems,
|
|
1129
1161
|
Y as saveJson,
|
|
1130
|
-
|
|
1162
|
+
Mn as setFuncName,
|
|
1131
1163
|
Rt as setPlaywrightPriorityLow,
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1164
|
+
Dn as sha256,
|
|
1165
|
+
Fn as sha256Buffer,
|
|
1166
|
+
It as subscribeJsErrors,
|
|
1135
1167
|
ae as testPage,
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1168
|
+
In as timeoutAbortController,
|
|
1169
|
+
Rn as toHex,
|
|
1170
|
+
_n as truncateString,
|
|
1171
|
+
Nn as urlGetBoolean,
|
|
1172
|
+
Wn as urlGetFloat,
|
|
1173
|
+
$n as urlGetInt,
|
|
1174
|
+
Bn as urlGetParams,
|
|
1175
|
+
zn as urlGetString,
|
|
1176
|
+
Jn as urlParamToBoolean,
|
|
1177
|
+
Un as urlParamToFloat,
|
|
1178
|
+
vn as urlParamToInt,
|
|
1147
1179
|
oe as useBrowser,
|
|
1148
1180
|
ie as useBrowserContext,
|
|
1149
1181
|
ce as usingCDPSession,
|
|
1150
|
-
|
|
1151
|
-
|
|
1182
|
+
Hn as validateMatchResult,
|
|
1183
|
+
Gn as waitObservable,
|
|
1184
|
+
Pt as walkPathHandleErrorDefault,
|
|
1152
1185
|
Zt as walkPaths,
|
|
1153
|
-
|
|
1154
|
-
|
|
1186
|
+
Kn as withConsoleReplace,
|
|
1187
|
+
Vn as withRetry,
|
|
1155
1188
|
mt as withTimeout
|
|
1156
1189
|
};
|