@voidzero-dev/vite-plus-test 0.1.2 → 0.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/dist/vendor/chai.mjs +279 -738
- package/dist/vendor/es-module-lexer.mjs +4 -5
- package/dist/vendor/estree-walker.mjs +18 -47
- package/dist/vendor/expect-type.mjs +10 -100
- package/dist/vendor/magic-string.mjs +152 -577
- package/dist/vendor/obug.mjs +1 -4
- package/dist/vendor/pathe.mjs +64 -112
- package/dist/vendor/picomatch.mjs +131 -323
- package/dist/vendor/{shared-BL6rqJMI.mjs → shared-BelWnsAF.mjs} +7 -12
- package/dist/vendor/std-env.mjs +2 -4
- package/dist/vendor/tinybench.mjs +7 -8
- package/dist/vendor/tinyexec.mjs +13 -25
- package/dist/vendor/tinyglobby.mjs +10 -21
- package/dist/vendor/tinyrainbow.mjs +1 -2
- package/package.json +3 -3
package/dist/vendor/obug.mjs
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { isatty } from "node:tty";
|
|
2
2
|
import { formatWithOptions, inspect } from "node:util";
|
|
3
|
-
|
|
4
3
|
//#region ../../node_modules/.pnpm/obug@2.1.1/node_modules/obug/dist/core.js
|
|
5
4
|
function coerce(value) {
|
|
6
5
|
if (value instanceof Error) return value.stack || value.message;
|
|
@@ -121,7 +120,6 @@ function enabled(name) {
|
|
|
121
120
|
for (const ns of names) if (matchesTemplate(name, ns)) return true;
|
|
122
121
|
return false;
|
|
123
122
|
}
|
|
124
|
-
|
|
125
123
|
//#endregion
|
|
126
124
|
//#region ../../node_modules/.pnpm/obug@2.1.1/node_modules/obug/dist/node.js
|
|
127
125
|
const colors = process.stderr.getColorDepth && process.stderr.getColorDepth() > 2 ? [
|
|
@@ -271,6 +269,5 @@ function enable(namespaces$1) {
|
|
|
271
269
|
enable$1(namespaces$1);
|
|
272
270
|
}
|
|
273
271
|
enable$1(process.env.DEBUG || "");
|
|
274
|
-
|
|
275
272
|
//#endregion
|
|
276
|
-
export { createDebug, disable, enable, enabled, namespaces };
|
|
273
|
+
export { createDebug, disable, enable, enabled, namespaces };
|
package/dist/vendor/pathe.mjs
CHANGED
|
@@ -15,7 +15,7 @@ let _lazyMatch = () => {
|
|
|
15
15
|
}, J = (r) => H(m({}, "__esModule", { value: true }), r), w = {};
|
|
16
16
|
q(w, { default: () => re });
|
|
17
17
|
var A = (r) => Array.isArray(r), d = (r) => typeof r == "function", Q = (r) => r.length === 0, W = (r) => typeof r == "number", K = (r) => typeof r == "object" && r !== null, X = (r) => r instanceof RegExp, b = (r) => typeof r == "string", h = (r) => r === void 0, Y = (r) => {
|
|
18
|
-
const e = new Map();
|
|
18
|
+
const e = /* @__PURE__ */ new Map();
|
|
19
19
|
return (n) => {
|
|
20
20
|
const a = e.get(n);
|
|
21
21
|
if (a) return a;
|
|
@@ -84,7 +84,7 @@ let _lazyMatch = () => {
|
|
|
84
84
|
}
|
|
85
85
|
return u >= e;
|
|
86
86
|
})));
|
|
87
|
-
}, tr = (r, e) => C(r, 0, 1), f = (r, e) => C(r, 0,
|
|
87
|
+
}, tr = (r, e) => C(r, 0, 1), f = (r, e) => C(r, 0, Infinity), x = (r, e) => {
|
|
88
88
|
const n = r.map(v);
|
|
89
89
|
return g(_(M((a) => {
|
|
90
90
|
for (let t = 0, o = n.length; t < o; t++) if (!n[t](a)) return false;
|
|
@@ -103,8 +103,7 @@ let _lazyMatch = () => {
|
|
|
103
103
|
return (!u || e) && (a.index = t, a.output.length !== o && (a.output.length = o)), u;
|
|
104
104
|
};
|
|
105
105
|
}, _ = (r, e) => {
|
|
106
|
-
|
|
107
|
-
return n;
|
|
106
|
+
return v(r);
|
|
108
107
|
}, g = (() => {
|
|
109
108
|
let r = 0;
|
|
110
109
|
return (e) => {
|
|
@@ -112,7 +111,7 @@ let _lazyMatch = () => {
|
|
|
112
111
|
return (t) => {
|
|
113
112
|
var o;
|
|
114
113
|
if (t.options.memoization === false) return n(t);
|
|
115
|
-
const u = t.index, s = (o = t.cache)[a] || (o[a] = new Map()), c = s.get(u);
|
|
114
|
+
const u = t.index, s = (o = t.cache)[a] || (o[a] = /* @__PURE__ */ new Map()), c = s.get(u);
|
|
116
115
|
if (c === false) return false;
|
|
117
116
|
if (W(c)) return t.index = c, true;
|
|
118
117
|
if (c) return t.index = c.index, c.output?.length && t.output.push(...c.output), true;
|
|
@@ -143,10 +142,7 @@ let _lazyMatch = () => {
|
|
|
143
142
|
throw new Error("Invalid rule");
|
|
144
143
|
}), P = "abcdefghijklmnopqrstuvwxyz", ir = (r) => {
|
|
145
144
|
let e = "";
|
|
146
|
-
for (; r > 0;)
|
|
147
|
-
const n = (r - 1) % 26;
|
|
148
|
-
e = P[n] + e, r = Math.floor((r - 1) / 26);
|
|
149
|
-
}
|
|
145
|
+
for (; r > 0;) e = P[(r - 1) % 26] + e, r = Math.floor((r - 1) / 26);
|
|
150
146
|
return e;
|
|
151
147
|
}, O = (r) => {
|
|
152
148
|
let e = 0;
|
|
@@ -160,45 +156,45 @@ let _lazyMatch = () => {
|
|
|
160
156
|
}, or = (r, e, n) => S(r, e).map((a) => String(a).padStart(n, "0")), R = (r, e) => S(O(r), O(e)).map(ir), p = (r) => r, z = (r) => ur((e) => rr(e, r, { memoization: false }).join("")), ur = (r) => {
|
|
161
157
|
const e = {};
|
|
162
158
|
return (n) => e[n] ?? (e[n] = r(n));
|
|
163
|
-
}, sr = i(/^\*\*\/\*$/, ".*"), cr = i(/^\*\*\/(\*)?([ a-zA-Z0-9._-]+)$/, (r, e, n) => `.*${e ? "" : "(?:^|/)"}${n.replaceAll(".", "\\.")}`), lr = i(/^\*\*\/(\*)?([ a-zA-Z0-9._-]*)\{([ a-zA-Z0-9._-]+(?:,[ a-zA-Z0-9._-]+)*)\}$/, (r, e, n, a) => `.*${e ? "" : "(?:^|/)"}${n.replaceAll(".", "\\.")}(?:${a.replaceAll(",", "|").replaceAll(".", "\\.")})`), y = i(/\\./, p), pr = i(/[$.*+?^(){}[\]\|]/, (r) => `\\${r}`), vr = i(/./, p),
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
]),
|
|
159
|
+
}, sr = i(/^\*\*\/\*$/, ".*"), cr = i(/^\*\*\/(\*)?([ a-zA-Z0-9._-]+)$/, (r, e, n) => `.*${e ? "" : "(?:^|/)"}${n.replaceAll(".", "\\.")}`), lr = i(/^\*\*\/(\*)?([ a-zA-Z0-9._-]*)\{([ a-zA-Z0-9._-]+(?:,[ a-zA-Z0-9._-]+)*)\}$/, (r, e, n, a) => `.*${e ? "" : "(?:^|/)"}${n.replaceAll(".", "\\.")}(?:${a.replaceAll(",", "|").replaceAll(".", "\\.")})`), y = i(/\\./, p), pr = i(/[$.*+?^(){}[\]\|]/, (r) => `\\${r}`), vr = i(/./, p), fr = l([i(/^(?:!!)*!(.*)$/, (r, e) => `(?!^${L(e)}$).*?`), i(/^(!!)+/, "")]), j = l([
|
|
160
|
+
i(/\/(\*\*\/)+/, "(?:/.+/|/)"),
|
|
161
|
+
i(/^(\*\*\/)+/, "(?:^|.*/)"),
|
|
162
|
+
i(/\/(\*\*)$/, "(?:/.*|$)"),
|
|
163
|
+
i(/\*\*/, ".*")
|
|
164
|
+
]), N = l([i(/\*\/(?!\*\*\/)/, "[^/]*/"), i(/\*/, "[^/]*")]), k = i("?", "[^/]"), $r = i("[", p), wr = i("]", p), Ar = i(/[!^]/, "^/"), br = i(/[a-z]-[a-z]|[0-9]-[0-9]/i, p), Er = l([
|
|
169
165
|
y,
|
|
170
|
-
|
|
166
|
+
i(/[$.*+?^(){}[\|]/, (r) => `\\${r}`),
|
|
171
167
|
br,
|
|
172
|
-
|
|
168
|
+
i(/[^\]]/, p)
|
|
173
169
|
]), B = x([
|
|
174
170
|
$r,
|
|
175
171
|
tr(Ar),
|
|
176
172
|
f(Er),
|
|
177
173
|
wr
|
|
178
|
-
]), Pr = i("{", "(?:"), Or = i("}", ")"),
|
|
179
|
-
Rr,
|
|
180
|
-
zr,
|
|
181
|
-
jr
|
|
182
|
-
]), I = x([
|
|
174
|
+
]), Pr = i("{", "(?:"), Or = i("}", ")"), I = x([
|
|
183
175
|
Pr,
|
|
184
|
-
|
|
176
|
+
l([
|
|
177
|
+
i(/(\d+)\.\.(\d+)/, (r, e, n) => or(+e, +n, Math.min(e.length, n.length)).join("|")),
|
|
178
|
+
i(/([a-z]+)\.\.([a-z]+)/, (r, e, n) => R(e, n).join("|")),
|
|
179
|
+
i(/([A-Z]+)\.\.([A-Z]+)/, (r, e, n) => R(e.toLowerCase(), n.toLowerCase()).join("|").toUpperCase())
|
|
180
|
+
]),
|
|
185
181
|
Or
|
|
186
|
-
]), kr = i("{", "(?:"), Br = i("}", ")"), Ir = i(",", "|"), Fr = i(/[$.*+?^(){[\]\|]/, (r) => `\\${r}`), Lr = i(/[^}]/, p),
|
|
187
|
-
j,
|
|
188
|
-
N,
|
|
189
|
-
k,
|
|
190
|
-
B,
|
|
191
|
-
I,
|
|
192
|
-
Zr,
|
|
193
|
-
y,
|
|
194
|
-
Fr,
|
|
195
|
-
Ir,
|
|
196
|
-
Lr
|
|
197
|
-
]), F = x([
|
|
182
|
+
]), kr = i("{", "(?:"), Br = i("}", ")"), Ir = i(",", "|"), Fr = i(/[$.*+?^(){[\]\|]/, (r) => `\\${r}`), Lr = i(/[^}]/, p), F = x([
|
|
198
183
|
kr,
|
|
199
|
-
f(
|
|
184
|
+
f(l([
|
|
185
|
+
j,
|
|
186
|
+
N,
|
|
187
|
+
k,
|
|
188
|
+
B,
|
|
189
|
+
I,
|
|
190
|
+
E(() => F),
|
|
191
|
+
y,
|
|
192
|
+
Fr,
|
|
193
|
+
Ir,
|
|
194
|
+
Lr
|
|
195
|
+
])),
|
|
200
196
|
Br
|
|
201
|
-
]),
|
|
197
|
+
]), L = z(f(l([
|
|
202
198
|
sr,
|
|
203
199
|
cr,
|
|
204
200
|
lr,
|
|
@@ -212,13 +208,13 @@ let _lazyMatch = () => {
|
|
|
212
208
|
y,
|
|
213
209
|
pr,
|
|
214
210
|
vr
|
|
215
|
-
]))
|
|
211
|
+
]))), Tr = i(/\\./, p), qr = i(/./, p), Yr = z(f(l([
|
|
216
212
|
Tr,
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
213
|
+
i(/\*\*\*+/, "*"),
|
|
214
|
+
i(/([^/{[(!])\*\*/, (r, e) => `${e}*`),
|
|
215
|
+
i(/(^|.)\*\*(?=[^*/)\]}])/, (r, e) => `${e}*`),
|
|
220
216
|
qr
|
|
221
|
-
]))
|
|
217
|
+
]))), $ = (r, e) => {
|
|
222
218
|
const n = Array.isArray(r) ? r : [r];
|
|
223
219
|
if (!n.length) return false;
|
|
224
220
|
const a = n.map($.compile), t = n.every((s) => /(\/(?:\*\*)?|\[\/\])$/.test(s)), o = e.replace(/[\\\/]+/g, "/").replace(/\/$/, t ? "/" : "");
|
|
@@ -240,9 +236,7 @@ const zeptomatch = (path, pattern) => {
|
|
|
240
236
|
};
|
|
241
237
|
const _DRIVE_LETTER_START_RE = /^[A-Za-z]:\//;
|
|
242
238
|
function normalizeWindowsPath(input = "") {
|
|
243
|
-
if (!input)
|
|
244
|
-
return input;
|
|
245
|
-
}
|
|
239
|
+
if (!input) return input;
|
|
246
240
|
return input.replace(/\\/g, "/").replace(_DRIVE_LETTER_START_RE, (r) => r.toUpperCase());
|
|
247
241
|
}
|
|
248
242
|
const _UNC_REGEX = /^[/\\]{2}/;
|
|
@@ -253,30 +247,20 @@ const _EXTNAME_RE = /.(\.[^./]+|\.)$/;
|
|
|
253
247
|
const _PATH_ROOT_RE = /^[/\\]|^[a-zA-Z]:[/\\]/;
|
|
254
248
|
const sep = "/";
|
|
255
249
|
const normalize = function(path) {
|
|
256
|
-
if (path.length === 0)
|
|
257
|
-
return ".";
|
|
258
|
-
}
|
|
250
|
+
if (path.length === 0) return ".";
|
|
259
251
|
path = normalizeWindowsPath(path);
|
|
260
252
|
const isUNCPath = path.match(_UNC_REGEX);
|
|
261
253
|
const isPathAbsolute = isAbsolute(path);
|
|
262
254
|
const trailingSeparator = path[path.length - 1] === "/";
|
|
263
255
|
path = normalizeString(path, !isPathAbsolute);
|
|
264
256
|
if (path.length === 0) {
|
|
265
|
-
if (isPathAbsolute)
|
|
266
|
-
return "/";
|
|
267
|
-
}
|
|
257
|
+
if (isPathAbsolute) return "/";
|
|
268
258
|
return trailingSeparator ? "./" : ".";
|
|
269
259
|
}
|
|
270
|
-
if (trailingSeparator)
|
|
271
|
-
|
|
272
|
-
}
|
|
273
|
-
if (_DRIVE_LETTER_RE.test(path)) {
|
|
274
|
-
path += "/";
|
|
275
|
-
}
|
|
260
|
+
if (trailingSeparator) path += "/";
|
|
261
|
+
if (_DRIVE_LETTER_RE.test(path)) path += "/";
|
|
276
262
|
if (isUNCPath) {
|
|
277
|
-
if (!isPathAbsolute) {
|
|
278
|
-
return `//./${path}`;
|
|
279
|
-
}
|
|
263
|
+
if (!isPathAbsolute) return `//./${path}`;
|
|
280
264
|
return `//${path}`;
|
|
281
265
|
}
|
|
282
266
|
return isPathAbsolute && !isAbsolute(path) ? `/${path}` : path;
|
|
@@ -284,28 +268,18 @@ const normalize = function(path) {
|
|
|
284
268
|
const join = function(...segments) {
|
|
285
269
|
let path = "";
|
|
286
270
|
for (const seg of segments) {
|
|
287
|
-
if (!seg)
|
|
288
|
-
continue;
|
|
289
|
-
}
|
|
271
|
+
if (!seg) continue;
|
|
290
272
|
if (path.length > 0) {
|
|
291
273
|
const pathTrailing = path[path.length - 1] === "/";
|
|
292
274
|
const segLeading = seg[0] === "/";
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
} else {
|
|
297
|
-
path += pathTrailing || segLeading ? seg : `/${seg}`;
|
|
298
|
-
}
|
|
299
|
-
} else {
|
|
300
|
-
path += seg;
|
|
301
|
-
}
|
|
275
|
+
if (pathTrailing && segLeading) path += seg.slice(1);
|
|
276
|
+
else path += pathTrailing || segLeading ? seg : `/${seg}`;
|
|
277
|
+
} else path += seg;
|
|
302
278
|
}
|
|
303
279
|
return normalize(path);
|
|
304
280
|
};
|
|
305
281
|
function cwd() {
|
|
306
|
-
if (typeof process !== "undefined" && typeof process.cwd === "function")
|
|
307
|
-
return process.cwd().replace(/\\/g, "/");
|
|
308
|
-
}
|
|
282
|
+
if (typeof process !== "undefined" && typeof process.cwd === "function") return process.cwd().replace(/\\/g, "/");
|
|
309
283
|
return "/";
|
|
310
284
|
}
|
|
311
285
|
const resolve = function(...arguments_) {
|
|
@@ -314,16 +288,12 @@ const resolve = function(...arguments_) {
|
|
|
314
288
|
let resolvedAbsolute = false;
|
|
315
289
|
for (let index = arguments_.length - 1; index >= -1 && !resolvedAbsolute; index--) {
|
|
316
290
|
const path = index >= 0 ? arguments_[index] : cwd();
|
|
317
|
-
if (!path || path.length === 0)
|
|
318
|
-
continue;
|
|
319
|
-
}
|
|
291
|
+
if (!path || path.length === 0) continue;
|
|
320
292
|
resolvedPath = `${path}/${resolvedPath}`;
|
|
321
293
|
resolvedAbsolute = isAbsolute(path);
|
|
322
294
|
}
|
|
323
295
|
resolvedPath = normalizeString(resolvedPath, !resolvedAbsolute);
|
|
324
|
-
if (resolvedAbsolute && !isAbsolute(resolvedPath)) {
|
|
325
|
-
return `/${resolvedPath}`;
|
|
326
|
-
}
|
|
296
|
+
if (resolvedAbsolute && !isAbsolute(resolvedPath)) return `/${resolvedPath}`;
|
|
327
297
|
return resolvedPath.length > 0 ? resolvedPath : ".";
|
|
328
298
|
};
|
|
329
299
|
function normalizeString(path, allowAboveRoot) {
|
|
@@ -333,13 +303,9 @@ function normalizeString(path, allowAboveRoot) {
|
|
|
333
303
|
let dots = 0;
|
|
334
304
|
let char = null;
|
|
335
305
|
for (let index = 0; index <= path.length; ++index) {
|
|
336
|
-
if (index < path.length)
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
break;
|
|
340
|
-
} else {
|
|
341
|
-
char = "/";
|
|
342
|
-
}
|
|
306
|
+
if (index < path.length) char = path[index];
|
|
307
|
+
else if (char === "/") break;
|
|
308
|
+
else char = "/";
|
|
343
309
|
if (char === "/") {
|
|
344
310
|
if (lastSlash === index - 1 || dots === 1);
|
|
345
311
|
else if (dots === 2) {
|
|
@@ -369,20 +335,14 @@ function normalizeString(path, allowAboveRoot) {
|
|
|
369
335
|
lastSegmentLength = 2;
|
|
370
336
|
}
|
|
371
337
|
} else {
|
|
372
|
-
if (res.length > 0) {
|
|
373
|
-
|
|
374
|
-
} else {
|
|
375
|
-
res = path.slice(lastSlash + 1, index);
|
|
376
|
-
}
|
|
338
|
+
if (res.length > 0) res += `/${path.slice(lastSlash + 1, index)}`;
|
|
339
|
+
else res = path.slice(lastSlash + 1, index);
|
|
377
340
|
lastSegmentLength = index - lastSlash - 1;
|
|
378
341
|
}
|
|
379
342
|
lastSlash = index;
|
|
380
343
|
dots = 0;
|
|
381
|
-
} else if (char === "." && dots !== -1)
|
|
382
|
-
|
|
383
|
-
} else {
|
|
384
|
-
dots = -1;
|
|
385
|
-
}
|
|
344
|
+
} else if (char === "." && dots !== -1) ++dots;
|
|
345
|
+
else dots = -1;
|
|
386
346
|
}
|
|
387
347
|
return res;
|
|
388
348
|
}
|
|
@@ -400,14 +360,10 @@ const extname = function(p) {
|
|
|
400
360
|
const relative = function(from, to) {
|
|
401
361
|
const _from = resolve(from).replace(_ROOT_FOLDER_RE, "$1").split("/");
|
|
402
362
|
const _to = resolve(to).replace(_ROOT_FOLDER_RE, "$1").split("/");
|
|
403
|
-
if (_to[0][1] === ":" && _from[0][1] === ":" && _from[0] !== _to[0])
|
|
404
|
-
return _to.join("/");
|
|
405
|
-
}
|
|
363
|
+
if (_to[0][1] === ":" && _from[0][1] === ":" && _from[0] !== _to[0]) return _to.join("/");
|
|
406
364
|
const _fromCopy = [..._from];
|
|
407
365
|
for (const segment of _fromCopy) {
|
|
408
|
-
if (_to[0] !== segment)
|
|
409
|
-
break;
|
|
410
|
-
}
|
|
366
|
+
if (_to[0] !== segment) break;
|
|
411
367
|
_from.shift();
|
|
412
368
|
_to.shift();
|
|
413
369
|
}
|
|
@@ -415,9 +371,7 @@ const relative = function(from, to) {
|
|
|
415
371
|
};
|
|
416
372
|
const dirname = function(p) {
|
|
417
373
|
const segments = normalizeWindowsPath(p).replace(/\/$/, "").split("/").slice(0, -1);
|
|
418
|
-
if (segments.length === 1 && _DRIVE_LETTER_RE.test(segments[0]))
|
|
419
|
-
segments[0] += "/";
|
|
420
|
-
}
|
|
374
|
+
if (segments.length === 1 && _DRIVE_LETTER_RE.test(segments[0])) segments[0] += "/";
|
|
421
375
|
return segments.join("/") || (isAbsolute(p) ? "/" : ".");
|
|
422
376
|
};
|
|
423
377
|
const format = function(p) {
|
|
@@ -470,13 +424,12 @@ const _path = {
|
|
|
470
424
|
parse,
|
|
471
425
|
relative,
|
|
472
426
|
resolve,
|
|
473
|
-
sep,
|
|
427
|
+
sep: "/",
|
|
474
428
|
toNamespacedPath
|
|
475
429
|
};
|
|
476
|
-
|
|
477
430
|
//#endregion
|
|
478
431
|
//#region ../../node_modules/.pnpm/pathe@2.0.3/node_modules/pathe/dist/index.mjs
|
|
479
|
-
const delimiter =
|
|
432
|
+
const delimiter = globalThis.process?.platform === "win32" ? ";" : ":";
|
|
480
433
|
const _platforms = {
|
|
481
434
|
posix: void 0,
|
|
482
435
|
win32: void 0
|
|
@@ -491,6 +444,5 @@ const mix = (del = delimiter) => {
|
|
|
491
444
|
};
|
|
492
445
|
const posix = /* @__PURE__ */ mix(":");
|
|
493
446
|
const win32 = /* @__PURE__ */ mix(";");
|
|
494
|
-
|
|
495
447
|
//#endregion
|
|
496
|
-
export { basename, posix as default, posix, delimiter, dirname, extname, format, isAbsolute, join, matchesGlob, normalize, normalizeString, parse, relative, resolve, sep, toNamespacedPath, win32 };
|
|
448
|
+
export { basename, posix as default, posix, delimiter, dirname, extname, format, isAbsolute, join, matchesGlob, normalize, normalizeString, parse, relative, resolve, sep, toNamespacedPath, win32 };
|