@sentry/mcp-server 0.10.0 → 0.11.0
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/api-client/client.cjs +4 -4
- package/dist/api-client/client.d.cts +3 -3
- package/dist/api-client/client.d.ts +3 -3
- package/dist/api-client/client.js +2 -2
- package/dist/api-client/client.test.cjs +8 -9
- package/dist/api-client/client.test.cjs.map +1 -1
- package/dist/api-client/client.test.js +4 -4
- package/dist/api-client/index.cjs +40 -38
- package/dist/api-client/index.d.cts +4 -4
- package/dist/api-client/index.d.ts +4 -4
- package/dist/api-client/index.js +5 -5
- package/dist/api-client/schema.cjs +35 -33
- package/dist/api-client/schema.d.cts +2 -2
- package/dist/api-client/schema.d.ts +2 -2
- package/dist/api-client/schema.js +2 -2
- package/dist/api-client/types.cjs +1 -1
- package/dist/api-client/types.d.cts +3 -3
- package/dist/api-client/types.d.ts +3 -3
- package/dist/api-client/types.js +1 -1
- package/dist/{chunk-CsIcISPO.js → chunk-BLXvPPr8.js} +1 -1
- package/dist/{chunk-BtT13l48.cjs → chunk-DWy1uDak.cjs} +0 -1
- package/dist/{client-J6VSRmQS.d.ts → client-Bxf4MxOz.d.cts} +7 -5
- package/dist/client-Bxf4MxOz.d.cts.map +1 -0
- package/dist/{client-Bz_PNC8o.js → client-D5xFZtxK.js} +14 -5
- package/dist/client-D5xFZtxK.js.map +1 -0
- package/dist/{client-tE6FD__9.d.cts → client-DOhBiaMJ.d.ts} +6 -4
- package/dist/client-DOhBiaMJ.d.ts.map +1 -0
- package/dist/{client-B4Ux5Zdg.cjs → client-GKHZSXgV.cjs} +14 -6
- package/dist/client-GKHZSXgV.cjs.map +1 -0
- package/dist/{dist-wiyJYfAH.cjs → dist-BlIWGSIM.cjs} +318 -164
- package/dist/dist-BlIWGSIM.cjs.map +1 -0
- package/dist/{dist-BKh-M1A1.js → dist-DDpQABxe.js} +318 -163
- package/dist/dist-DDpQABxe.js.map +1 -0
- package/dist/errors-B9fwS-aP.cjs +21 -0
- package/dist/errors-B9fwS-aP.cjs.map +1 -0
- package/dist/errors-BJSrT6Ou.js +15 -0
- package/dist/errors-BJSrT6Ou.js.map +1 -0
- package/dist/errors.cjs +3 -0
- package/dist/errors.d.cts +12 -0
- package/dist/errors.d.cts.map +1 -0
- package/dist/errors.d.ts +12 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/errors.js +3 -0
- package/dist/errors.test.cjs +24 -0
- package/dist/errors.test.cjs.map +1 -0
- package/dist/errors.test.d.cts +1 -0
- package/dist/errors.test.d.ts +1 -0
- package/dist/errors.test.js +24 -0
- package/dist/errors.test.js.map +1 -0
- package/dist/{formatting-ggD6YRYR.js → formatting-BaARL2gT.js} +1 -1
- package/dist/{formatting-ggD6YRYR.js.map → formatting-BaARL2gT.js.map} +1 -1
- package/dist/{formatting-B0SJqiqX.cjs → formatting-C2kN0ok6.cjs} +1 -2
- package/dist/{formatting-B0SJqiqX.cjs.map → formatting-C2kN0ok6.cjs.map} +1 -1
- package/dist/index.cjs +19 -19
- package/dist/index.js +18 -17
- package/dist/index.js.map +1 -1
- package/dist/internal/formatting.cjs +4 -4
- package/dist/internal/formatting.d.cts +4 -5
- package/dist/internal/formatting.d.cts.map +1 -1
- package/dist/internal/formatting.d.ts +4 -5
- package/dist/internal/formatting.d.ts.map +1 -1
- package/dist/internal/formatting.js +1 -1
- package/dist/internal/issue-helpers.cjs +4 -4
- package/dist/internal/issue-helpers.d.cts +2 -2
- package/dist/internal/issue-helpers.d.cts.map +1 -1
- package/dist/internal/issue-helpers.d.ts +2 -2
- package/dist/internal/issue-helpers.d.ts.map +1 -1
- package/dist/internal/issue-helpers.js +1 -1
- package/dist/internal/issue-helpers.test.cjs +21 -25
- package/dist/internal/issue-helpers.test.cjs.map +1 -1
- package/dist/internal/issue-helpers.test.js +5 -8
- package/dist/internal/issue-helpers.test.js.map +1 -1
- package/dist/{issue-helpers-DbsECZFq.cjs → issue-helpers-71XgJVXC.cjs} +8 -3
- package/dist/issue-helpers-71XgJVXC.cjs.map +1 -0
- package/dist/{issue-helpers-CyoHu5j4.js → issue-helpers-CSNNO03f.js} +8 -2
- package/dist/issue-helpers-CSNNO03f.js.map +1 -0
- package/dist/{logging-BEMgC5SA.cjs → logging-ByvSjT6V.cjs} +2 -3
- package/dist/{logging-BEMgC5SA.cjs.map → logging-ByvSjT6V.cjs.map} +1 -1
- package/dist/{logging-Cxm8lQvg.js → logging-CXLD0FFB.js} +1 -1
- package/dist/{logging-Cxm8lQvg.js.map → logging-CXLD0FFB.js.map} +1 -1
- package/dist/logging.cjs +2 -2
- package/dist/logging.d.cts +1 -2
- package/dist/logging.d.cts.map +1 -1
- package/dist/logging.d.ts +1 -2
- package/dist/logging.d.ts.map +1 -1
- package/dist/logging.js +1 -1
- package/dist/{magic-string.es-m-ldRjOa.cjs → magic-string.es-CybcVAw7.cjs} +2 -3
- package/dist/{magic-string.es-m-ldRjOa.cjs.map → magic-string.es-CybcVAw7.cjs.map} +1 -1
- package/dist/{promptDefinitions-pHRpPOpJ.cjs → promptDefinitions-D3ll3qCd.cjs} +3 -4
- package/dist/{promptDefinitions-pHRpPOpJ.cjs.map → promptDefinitions-D3ll3qCd.cjs.map} +1 -1
- package/dist/{promptDefinitions-BR7PxWcH.d.cts → promptDefinitions-DMucOchd.d.cts} +3 -3
- package/dist/promptDefinitions-DMucOchd.d.cts.map +1 -0
- package/dist/{promptDefinitions-tpKruPny.d.ts → promptDefinitions-H0q1_X-K.d.ts} +4 -4
- package/dist/promptDefinitions-H0q1_X-K.d.ts.map +1 -0
- package/dist/{promptDefinitions-DBNOeSg-.js → promptDefinitions-aKmUZWWO.js} +2 -2
- package/dist/{promptDefinitions-DBNOeSg-.js.map → promptDefinitions-aKmUZWWO.js.map} +1 -1
- package/dist/promptDefinitions.cjs +3 -3
- package/dist/promptDefinitions.d.cts +1 -1
- package/dist/promptDefinitions.d.ts +1 -1
- package/dist/promptDefinitions.js +2 -2
- package/dist/{prompts-DgWOD2rU.js → prompts-CzD0yl7Z.js} +1 -1
- package/dist/{prompts-DgWOD2rU.js.map → prompts-CzD0yl7Z.js.map} +1 -1
- package/dist/{prompts-nfFU-zY-.cjs → prompts-DMwoay8l.cjs} +1 -2
- package/dist/{prompts-nfFU-zY-.cjs.map → prompts-DMwoay8l.cjs.map} +1 -1
- package/dist/prompts.cjs +2 -2
- package/dist/prompts.d.cts +4 -5
- package/dist/prompts.d.cts.map +1 -1
- package/dist/prompts.d.ts +4 -5
- package/dist/prompts.d.ts.map +1 -1
- package/dist/prompts.js +1 -1
- package/dist/{resources-BAE7VVZZ.cjs → resources-D6TW2ER0.cjs} +1 -2
- package/dist/{resources-BAE7VVZZ.cjs.map → resources-D6TW2ER0.cjs.map} +1 -1
- package/dist/{resources-OM3EAnnj.js → resources-x-GaokG8.js} +1 -1
- package/dist/{resources-OM3EAnnj.js.map → resources-x-GaokG8.js.map} +1 -1
- package/dist/resources.cjs +2 -2
- package/dist/resources.d.cts +0 -1
- package/dist/resources.d.cts.map +1 -1
- package/dist/resources.d.ts +0 -1
- package/dist/resources.d.ts.map +1 -1
- package/dist/resources.js +1 -1
- package/dist/{schema-jk88gqOu.cjs → schema-B8lT632E.cjs} +2 -3
- package/dist/{schema-jk88gqOu.cjs.map → schema-B8lT632E.cjs.map} +1 -1
- package/dist/{schema-BKa41TQ4.js → schema-BkHf97d7.js} +1 -1
- package/dist/{schema-BKa41TQ4.js.map → schema-BkHf97d7.js.map} +1 -1
- package/dist/{schema-PvgLrC1b.d.cts → schema-C-MLkWMc.d.ts} +59 -24
- package/dist/schema-C-MLkWMc.d.ts.map +1 -0
- package/dist/{schema-Dltbjui7.js → schema-CewAKS9A.js} +11 -2
- package/dist/schema-CewAKS9A.js.map +1 -0
- package/dist/{schema-3VLYcf4D.cjs → schema-DkyWSqp_.cjs} +23 -3
- package/dist/schema-DkyWSqp_.cjs.map +1 -0
- package/dist/{schema-B7A-FyIi.d.ts → schema-DqxkW9Tx.d.cts} +59 -24
- package/dist/schema-DqxkW9Tx.d.cts.map +1 -0
- package/dist/schema.cjs +11 -11
- package/dist/schema.d.cts +1 -2
- package/dist/schema.d.cts.map +1 -1
- package/dist/schema.d.ts +1 -2
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +1 -1
- package/dist/{server-VwFSUPQn.cjs → server-pGtEIwE3.cjs} +33 -27
- package/dist/server-pGtEIwE3.cjs.map +1 -0
- package/dist/{server-yb4PkNyo.js → server-qpWdf-ST.js} +32 -25
- package/dist/server-qpWdf-ST.js.map +1 -0
- package/dist/server.cjs +16 -15
- package/dist/server.d.cts +4 -5
- package/dist/server.d.cts.map +1 -1
- package/dist/server.d.ts +4 -5
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +15 -14
- package/dist/{stdio-DkU2-spy.js → stdio-D8u2W847.js} +2 -2
- package/dist/{stdio-DkU2-spy.js.map → stdio-D8u2W847.js.map} +1 -1
- package/dist/{stdio-65sYKLOk.cjs → stdio-DydB2Pxu.cjs} +3 -4
- package/dist/{stdio-65sYKLOk.cjs.map → stdio-DydB2Pxu.cjs.map} +1 -1
- package/dist/test-setup.cjs +233 -181
- package/dist/test-setup.cjs.map +1 -1
- package/dist/test-setup.js +233 -181
- package/dist/test-setup.js.map +1 -1
- package/dist/{toolDefinitions-Bb_1ejkl.js → toolDefinitions-BSC2D_S-.js} +14 -3
- package/dist/toolDefinitions-BSC2D_S-.js.map +1 -0
- package/dist/{toolDefinitions-DIhvw3vk.cjs → toolDefinitions-BtHN8t_d.cjs} +15 -5
- package/dist/toolDefinitions-BtHN8t_d.cjs.map +1 -0
- package/dist/{toolDefinitions-q_1-70fG.d.ts → toolDefinitions-Dp13BpEu.d.cts} +37 -5
- package/dist/toolDefinitions-Dp13BpEu.d.cts.map +1 -0
- package/dist/{toolDefinitions-B94CNDbt.d.cts → toolDefinitions-fQrpWznJ.d.ts} +36 -4
- package/dist/toolDefinitions-fQrpWznJ.d.ts.map +1 -0
- package/dist/toolDefinitions.cjs +3 -3
- package/dist/toolDefinitions.d.cts +1 -1
- package/dist/toolDefinitions.d.ts +1 -1
- package/dist/toolDefinitions.js +2 -2
- package/dist/toolDefinitions.test.cjs +3 -4
- package/dist/toolDefinitions.test.cjs.map +1 -1
- package/dist/toolDefinitions.test.js +3 -3
- package/dist/{tools-CMFpMPpD.js → tools-4Rtn4WEf.js} +27 -10
- package/dist/tools-4Rtn4WEf.js.map +1 -0
- package/dist/{tools-BdkmyaZo.cjs → tools-DHHqAqP9.cjs} +28 -12
- package/dist/tools-DHHqAqP9.cjs.map +1 -0
- package/dist/tools.cjs +10 -9
- package/dist/tools.d.cts +35 -6
- package/dist/tools.d.cts.map +1 -1
- package/dist/tools.d.ts +35 -6
- package/dist/tools.d.ts.map +1 -1
- package/dist/tools.js +9 -8
- package/dist/tools.test.cjs +47 -32
- package/dist/tools.test.cjs.map +1 -1
- package/dist/tools.test.js +28 -12
- package/dist/tools.test.js.map +1 -1
- package/dist/transports/stdio.cjs +17 -16
- package/dist/transports/stdio.d.cts +4 -5
- package/dist/transports/stdio.d.cts.map +1 -1
- package/dist/transports/stdio.d.ts +4 -5
- package/dist/transports/stdio.d.ts.map +1 -1
- package/dist/transports/stdio.js +16 -15
- package/dist/{types-OeoNXRm-.d.cts → types-CbLyQvVe.d.cts} +3 -4
- package/dist/types-CbLyQvVe.d.cts.map +1 -0
- package/dist/{types-CN4NEway.d.ts → types-CcffrLXB.d.cts} +5 -5
- package/dist/types-CcffrLXB.d.cts.map +1 -0
- package/dist/{types-jftb-CP9.d.ts → types-CfJ51LyL.d.ts} +3 -4
- package/dist/types-CfJ51LyL.d.ts.map +1 -0
- package/dist/{types-B03G337q.d.cts → types-DuUmV9zh.d.ts} +5 -5
- package/dist/types-DuUmV9zh.d.ts.map +1 -0
- package/dist/types.d.cts +3 -3
- package/dist/types.d.ts +3 -3
- package/dist/version-BT9r_3jm.js +6 -0
- package/dist/{version-TjO7fHpC.js.map → version-BT9r_3jm.js.map} +1 -1
- package/dist/{version-CDnh7DyW.cjs → version-CRzAHHGZ.cjs} +2 -3
- package/dist/{version-CDnh7DyW.cjs.map → version-CRzAHHGZ.cjs.map} +1 -1
- package/dist/version.cjs +2 -2
- package/dist/version.d.cts +1 -2
- package/dist/version.d.cts.map +1 -1
- package/dist/version.d.ts +1 -2
- package/dist/version.d.ts.map +1 -1
- package/dist/version.js +1 -1
- package/dist/{vi.ClIskdbk-De9q3829.js → vi.bdSIJ99Y-BfJr7I2s.js} +241 -171
- package/dist/vi.bdSIJ99Y-BfJr7I2s.js.map +1 -0
- package/dist/{vi.ClIskdbk-Bs263gvI.cjs → vi.bdSIJ99Y-Dft_B_Ta.cjs} +243 -182
- package/dist/vi.bdSIJ99Y-Dft_B_Ta.cjs.map +1 -0
- package/package.json +8 -8
- package/dist/client-B4Ux5Zdg.cjs.map +0 -1
- package/dist/client-Bz_PNC8o.js.map +0 -1
- package/dist/client-J6VSRmQS.d.ts.map +0 -1
- package/dist/client-tE6FD__9.d.cts.map +0 -1
- package/dist/dist-BKh-M1A1.js.map +0 -1
- package/dist/dist-wiyJYfAH.cjs.map +0 -1
- package/dist/issue-helpers-CyoHu5j4.js.map +0 -1
- package/dist/issue-helpers-DbsECZFq.cjs.map +0 -1
- package/dist/promptDefinitions-BR7PxWcH.d.cts.map +0 -1
- package/dist/promptDefinitions-tpKruPny.d.ts.map +0 -1
- package/dist/schema-3VLYcf4D.cjs.map +0 -1
- package/dist/schema-B7A-FyIi.d.ts.map +0 -1
- package/dist/schema-Dltbjui7.js.map +0 -1
- package/dist/schema-PvgLrC1b.d.cts.map +0 -1
- package/dist/server-VwFSUPQn.cjs.map +0 -1
- package/dist/server-yb4PkNyo.js.map +0 -1
- package/dist/toolDefinitions-B94CNDbt.d.cts.map +0 -1
- package/dist/toolDefinitions-Bb_1ejkl.js.map +0 -1
- package/dist/toolDefinitions-DIhvw3vk.cjs.map +0 -1
- package/dist/toolDefinitions-q_1-70fG.d.ts.map +0 -1
- package/dist/tools-BdkmyaZo.cjs.map +0 -1
- package/dist/tools-CMFpMPpD.js.map +0 -1
- package/dist/types-B03G337q.d.cts.map +0 -1
- package/dist/types-CN4NEway.d.ts.map +0 -1
- package/dist/types-OeoNXRm-.d.cts.map +0 -1
- package/dist/types-jftb-CP9.d.ts.map +0 -1
- package/dist/version-TjO7fHpC.js +0 -6
- package/dist/vi.ClIskdbk-Bs263gvI.cjs.map +0 -1
- package/dist/vi.ClIskdbk-De9q3829.js.map +0 -1
- /package/dist/{api-client-9mzrj2HY.js → api-client-CL1WDkw9.cjs} +0 -0
- /package/dist/{api-client-CEBuz3Zu.cjs → api-client-CNv_hbPO.js} +0 -0
- /package/dist/{types-H-TSmRpm.js → types-6zHoEWAx.js} +0 -0
- /package/dist/{types-o3zWarRp.cjs → types-MYBaygjr.cjs} +0 -0
|
@@ -1,85 +1,132 @@
|
|
|
1
|
-
import { __require } from "./chunk-
|
|
2
|
-
import { Assertion, assert, assertTypes, createSimpleStackTrace, diff, expect, format, getCurrentTest, getNames, getSafeTimers, getTestName, getType, isObject, parseSingleStack, plugins, printDiffOrStringify, processError, stringify, u, use, utils_exports } from "./dist-
|
|
1
|
+
import { __require } from "./chunk-BLXvPPr8.js";
|
|
2
|
+
import { Assertion, assert, assertTypes, createSimpleStackTrace, diff, expect, format, getCurrentTest, getNames, getSafeTimers, getTestName, getType, isObject, parseSingleStack, plugins, printDiffOrStringify, processError, stringify, u, use, utils_exports } from "./dist-DDpQABxe.js";
|
|
3
3
|
|
|
4
|
-
//#region ../../node_modules/.pnpm/tinyspy@
|
|
5
|
-
function
|
|
6
|
-
if (!
|
|
7
|
-
}
|
|
8
|
-
function
|
|
9
|
-
return typeof
|
|
10
|
-
}
|
|
11
|
-
function
|
|
12
|
-
return
|
|
13
|
-
}
|
|
14
|
-
function
|
|
15
|
-
Object.defineProperty(
|
|
16
|
-
}
|
|
17
|
-
function
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
4
|
+
//#region ../../node_modules/.pnpm/tinyspy@4.0.3/node_modules/tinyspy/dist/index.js
|
|
5
|
+
function assert$1(condition, message) {
|
|
6
|
+
if (!condition) throw new Error(message);
|
|
7
|
+
}
|
|
8
|
+
function isType(type, value) {
|
|
9
|
+
return typeof value === type;
|
|
10
|
+
}
|
|
11
|
+
function isPromise(value) {
|
|
12
|
+
return value instanceof Promise;
|
|
13
|
+
}
|
|
14
|
+
function define(obj, key, descriptor) {
|
|
15
|
+
Object.defineProperty(obj, key, descriptor);
|
|
16
|
+
}
|
|
17
|
+
function defineValue(obj, key, value) {
|
|
18
|
+
define(obj, key, {
|
|
19
|
+
value,
|
|
20
|
+
configurable: !0,
|
|
21
|
+
writable: !0
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
var SYMBOL_STATE = Symbol.for("tinyspy:spy");
|
|
25
|
+
var spies = /* @__PURE__ */ new Set(), reset = (state) => {
|
|
26
|
+
state.called = !1, state.callCount = 0, state.calls = [], state.results = [], state.resolves = [], state.next = [];
|
|
27
|
+
}, defineState = (spy2) => (define(spy2, SYMBOL_STATE, { value: { reset: () => reset(spy2[SYMBOL_STATE]) } }), spy2[SYMBOL_STATE]), getInternalState = (spy2) => spy2[SYMBOL_STATE] || defineState(spy2);
|
|
28
|
+
function createInternalSpy(cb) {
|
|
29
|
+
assert$1(isType("function", cb) || isType("undefined", cb), "cannot spy on a non-function value");
|
|
30
|
+
let fn$1 = function(...args) {
|
|
31
|
+
let state2 = getInternalState(fn$1);
|
|
32
|
+
state2.called = !0, state2.callCount++, state2.calls.push(args);
|
|
33
|
+
let next = state2.next.shift();
|
|
34
|
+
if (next) {
|
|
35
|
+
state2.results.push(next);
|
|
36
|
+
let [type2, result2] = next;
|
|
37
|
+
if (type2 === "ok") return result2;
|
|
38
|
+
throw result2;
|
|
35
39
|
}
|
|
36
|
-
let
|
|
37
|
-
if (
|
|
38
|
-
new.target ?
|
|
39
|
-
} catch (
|
|
40
|
-
throw
|
|
40
|
+
let result, type = "ok", resultIndex = state2.results.length;
|
|
41
|
+
if (state2.impl) try {
|
|
42
|
+
new.target ? result = Reflect.construct(state2.impl, args, new.target) : result = state2.impl.apply(this, args), type = "ok";
|
|
43
|
+
} catch (err) {
|
|
44
|
+
throw result = err, type = "error", state2.results.push([type, err]), err;
|
|
41
45
|
}
|
|
42
|
-
let
|
|
43
|
-
return
|
|
46
|
+
let resultTuple = [type, result];
|
|
47
|
+
return isPromise(result) && result.then((r) => state2.resolves[resultIndex] = ["ok", r], (e) => state2.resolves[resultIndex] = ["error", e]), state2.results.push(resultTuple), result;
|
|
44
48
|
};
|
|
45
|
-
|
|
46
|
-
let
|
|
47
|
-
return
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
|
|
49
|
+
defineValue(fn$1, "_isMockFunction", !0), defineValue(fn$1, "length", cb ? cb.length : 0), defineValue(fn$1, "name", cb && cb.name || "spy");
|
|
50
|
+
let state = getInternalState(fn$1);
|
|
51
|
+
return state.reset(), state.impl = cb, fn$1;
|
|
52
|
+
}
|
|
53
|
+
function isMockFunction$1(obj) {
|
|
54
|
+
return !!obj && obj._isMockFunction === !0;
|
|
55
|
+
}
|
|
56
|
+
var getDescriptor$1 = (obj, method) => {
|
|
57
|
+
let objDescriptor = Object.getOwnPropertyDescriptor(obj, method);
|
|
58
|
+
if (objDescriptor) return [obj, objDescriptor];
|
|
59
|
+
let currentProto = Object.getPrototypeOf(obj);
|
|
60
|
+
for (; currentProto !== null;) {
|
|
61
|
+
let descriptor = Object.getOwnPropertyDescriptor(currentProto, method);
|
|
62
|
+
if (descriptor) return [currentProto, descriptor];
|
|
63
|
+
currentProto = Object.getPrototypeOf(currentProto);
|
|
64
|
+
}
|
|
65
|
+
}, setPototype = (fn$1, val) => {
|
|
66
|
+
val != null && typeof val == "function" && val.prototype != null && Object.setPrototypeOf(fn$1.prototype, val.prototype);
|
|
51
67
|
};
|
|
52
|
-
function
|
|
53
|
-
|
|
54
|
-
let [
|
|
55
|
-
if (!
|
|
56
|
-
if ("getter" in
|
|
57
|
-
if ("getter" in
|
|
58
|
-
if ("setter" in
|
|
68
|
+
function internalSpyOn(obj, methodName, mock) {
|
|
69
|
+
assert$1(!isType("undefined", obj), "spyOn could not find an object to spy upon"), assert$1(isType("object", obj) || isType("function", obj), "cannot spyOn on a primitive value");
|
|
70
|
+
let [accessName, accessType] = (() => {
|
|
71
|
+
if (!isType("object", methodName)) return [methodName, "value"];
|
|
72
|
+
if ("getter" in methodName && "setter" in methodName) throw new Error("cannot spy on both getter and setter");
|
|
73
|
+
if ("getter" in methodName) return [methodName.getter, "get"];
|
|
74
|
+
if ("setter" in methodName) return [methodName.setter, "set"];
|
|
59
75
|
throw new Error("specify getter or setter to spy on");
|
|
60
|
-
})(),
|
|
61
|
-
|
|
62
|
-
let
|
|
63
|
-
|
|
64
|
-
let
|
|
65
|
-
|
|
66
|
-
let
|
|
67
|
-
let { value
|
|
76
|
+
})(), [originalDescriptorObject, originalDescriptor] = getDescriptor$1(obj, accessName) || [];
|
|
77
|
+
assert$1(originalDescriptor || accessName in obj, `${String(accessName)} does not exist`);
|
|
78
|
+
let ssr = !1;
|
|
79
|
+
accessType === "value" && originalDescriptor && !originalDescriptor.value && originalDescriptor.get && (accessType = "get", ssr = !0, mock = originalDescriptor.get());
|
|
80
|
+
let original;
|
|
81
|
+
originalDescriptor ? original = originalDescriptor[accessType] : accessType !== "value" ? original = () => obj[accessName] : original = obj[accessName], original && isSpyFunction(original) && (original = original[SYMBOL_STATE].getOriginal());
|
|
82
|
+
let reassign = (cb) => {
|
|
83
|
+
let { value,...desc } = originalDescriptor || {
|
|
68
84
|
configurable: !0,
|
|
69
85
|
writable: !0
|
|
70
86
|
};
|
|
71
|
-
|
|
72
|
-
},
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
let
|
|
77
|
-
|
|
87
|
+
accessType !== "value" && delete desc.writable, desc[accessType] = cb, define(obj, accessName, desc);
|
|
88
|
+
}, restore = () => {
|
|
89
|
+
originalDescriptorObject !== obj ? Reflect.deleteProperty(obj, accessName) : originalDescriptor && !original ? define(obj, accessName, originalDescriptor) : reassign(original);
|
|
90
|
+
};
|
|
91
|
+
mock || (mock = original);
|
|
92
|
+
let spy2 = wrap(createInternalSpy(mock), mock);
|
|
93
|
+
accessType === "value" && setPototype(spy2, original);
|
|
94
|
+
let state = spy2[SYMBOL_STATE];
|
|
95
|
+
return defineValue(state, "restore", restore), defineValue(state, "getOriginal", () => ssr ? original() : original), defineValue(state, "willCall", (newCb) => (state.impl = newCb, spy2)), reassign(ssr ? () => (setPototype(spy2, mock), spy2) : spy2), spies.add(spy2), spy2;
|
|
96
|
+
}
|
|
97
|
+
var ignoreProperties = /* @__PURE__ */ new Set([
|
|
98
|
+
"length",
|
|
99
|
+
"name",
|
|
100
|
+
"prototype"
|
|
101
|
+
]);
|
|
102
|
+
function getAllProperties(original) {
|
|
103
|
+
let properties = /* @__PURE__ */ new Set(), descriptors2 = {};
|
|
104
|
+
for (; original && original !== Object.prototype && original !== Function.prototype;) {
|
|
105
|
+
let ownProperties = [...Object.getOwnPropertyNames(original), ...Object.getOwnPropertySymbols(original)];
|
|
106
|
+
for (let prop of ownProperties) descriptors2[prop] || ignoreProperties.has(prop) || (properties.add(prop), descriptors2[prop] = Object.getOwnPropertyDescriptor(original, prop));
|
|
107
|
+
original = Object.getPrototypeOf(original);
|
|
108
|
+
}
|
|
109
|
+
return {
|
|
110
|
+
properties,
|
|
111
|
+
descriptors: descriptors2
|
|
112
|
+
};
|
|
113
|
+
}
|
|
114
|
+
function wrap(mock, original) {
|
|
115
|
+
if (!original || SYMBOL_STATE in original) return mock;
|
|
116
|
+
let { properties, descriptors: descriptors2 } = getAllProperties(original);
|
|
117
|
+
for (let key of properties) {
|
|
118
|
+
let descriptor = descriptors2[key];
|
|
119
|
+
getDescriptor$1(mock, key) || define(mock, key, descriptor);
|
|
120
|
+
}
|
|
121
|
+
return mock;
|
|
122
|
+
}
|
|
123
|
+
function isSpyFunction(obj) {
|
|
124
|
+
return isMockFunction$1(obj) && "getOriginal" in obj[SYMBOL_STATE];
|
|
78
125
|
}
|
|
79
126
|
|
|
80
127
|
//#endregion
|
|
81
|
-
//#region ../../node_modules/.pnpm/@vitest+spy@3.
|
|
82
|
-
const mocks = new Set();
|
|
128
|
+
//#region ../../node_modules/.pnpm/@vitest+spy@3.2.0/node_modules/@vitest/spy/dist/index.js
|
|
129
|
+
const mocks = /* @__PURE__ */ new Set();
|
|
83
130
|
function isMockFunction(fn$1) {
|
|
84
131
|
return typeof fn$1 === "function" && "_isMockFunction" in fn$1 && fn$1._isMockFunction;
|
|
85
132
|
}
|
|
@@ -89,17 +136,25 @@ function spyOn(obj, method, accessType) {
|
|
|
89
136
|
set: "setter"
|
|
90
137
|
};
|
|
91
138
|
const objMethod = accessType ? { [dictionary[accessType]]: method } : method;
|
|
92
|
-
|
|
93
|
-
|
|
139
|
+
let state;
|
|
140
|
+
const descriptor = getDescriptor(obj, method);
|
|
141
|
+
const fn$1 = descriptor && descriptor[accessType || "value"];
|
|
142
|
+
if (isMockFunction(fn$1)) state = fn$1.mock._state();
|
|
143
|
+
const stub = internalSpyOn(obj, objMethod);
|
|
144
|
+
const spy = enhanceSpy(stub);
|
|
145
|
+
if (state) spy.mock._state(state);
|
|
146
|
+
return spy;
|
|
94
147
|
}
|
|
95
148
|
let callOrder = 0;
|
|
96
149
|
function enhanceSpy(spy) {
|
|
97
150
|
const stub = spy;
|
|
98
151
|
let implementation;
|
|
152
|
+
let onceImplementations = [];
|
|
153
|
+
let implementationChangedTemporarily = false;
|
|
99
154
|
let instances = [];
|
|
100
155
|
let contexts = [];
|
|
101
156
|
let invocations = [];
|
|
102
|
-
const state =
|
|
157
|
+
const state = getInternalState(spy);
|
|
103
158
|
const mockContext = {
|
|
104
159
|
get calls() {
|
|
105
160
|
return state.calls;
|
|
@@ -133,10 +188,20 @@ function enhanceSpy(spy) {
|
|
|
133
188
|
},
|
|
134
189
|
get lastCall() {
|
|
135
190
|
return state.calls[state.calls.length - 1];
|
|
191
|
+
},
|
|
192
|
+
_state(state$1) {
|
|
193
|
+
if (state$1) {
|
|
194
|
+
implementation = state$1.implementation;
|
|
195
|
+
onceImplementations = state$1.onceImplementations;
|
|
196
|
+
implementationChangedTemporarily = state$1.implementationChangedTemporarily;
|
|
197
|
+
}
|
|
198
|
+
return {
|
|
199
|
+
implementation,
|
|
200
|
+
onceImplementations,
|
|
201
|
+
implementationChangedTemporarily
|
|
202
|
+
};
|
|
136
203
|
}
|
|
137
204
|
};
|
|
138
|
-
let onceImplementations = [];
|
|
139
|
-
let implementationChangedTemporarily = false;
|
|
140
205
|
function mockCall(...args) {
|
|
141
206
|
instances.push(this);
|
|
142
207
|
contexts.push(this);
|
|
@@ -168,6 +233,7 @@ function enhanceSpy(spy) {
|
|
|
168
233
|
state.restore();
|
|
169
234
|
return stub;
|
|
170
235
|
};
|
|
236
|
+
if (Symbol.dispose) stub[Symbol.dispose] = () => stub.mockRestore();
|
|
171
237
|
stub.getMockImplementation = () => implementationChangedTemporarily ? implementation : onceImplementations.at(0) || implementation;
|
|
172
238
|
stub.mockImplementation = (fn$1) => {
|
|
173
239
|
implementation = fn$1;
|
|
@@ -183,16 +249,16 @@ function enhanceSpy(spy) {
|
|
|
183
249
|
implementation = fn$1;
|
|
184
250
|
state.willCall(mockCall);
|
|
185
251
|
implementationChangedTemporarily = true;
|
|
186
|
-
const reset = () => {
|
|
252
|
+
const reset$1 = () => {
|
|
187
253
|
implementation = originalImplementation;
|
|
188
254
|
implementationChangedTemporarily = false;
|
|
189
255
|
};
|
|
190
256
|
const result = cb();
|
|
191
|
-
if (result
|
|
192
|
-
reset();
|
|
257
|
+
if (typeof result === "object" && result && typeof result.then === "function") return result.then(() => {
|
|
258
|
+
reset$1();
|
|
193
259
|
return stub;
|
|
194
260
|
});
|
|
195
|
-
reset();
|
|
261
|
+
reset$1();
|
|
196
262
|
return stub;
|
|
197
263
|
}
|
|
198
264
|
stub.withImplementation = withImplementation;
|
|
@@ -211,13 +277,23 @@ function enhanceSpy(spy) {
|
|
|
211
277
|
return stub;
|
|
212
278
|
}
|
|
213
279
|
function fn(implementation) {
|
|
214
|
-
const enhancedSpy = enhanceSpy(
|
|
280
|
+
const enhancedSpy = enhanceSpy(internalSpyOn({ spy: implementation || function() {} }, "spy"));
|
|
215
281
|
if (implementation) enhancedSpy.mockImplementation(implementation);
|
|
216
282
|
return enhancedSpy;
|
|
217
283
|
}
|
|
284
|
+
function getDescriptor(obj, method) {
|
|
285
|
+
const objDescriptor = Object.getOwnPropertyDescriptor(obj, method);
|
|
286
|
+
if (objDescriptor) return objDescriptor;
|
|
287
|
+
let currentProto = Object.getPrototypeOf(obj);
|
|
288
|
+
while (currentProto !== null) {
|
|
289
|
+
const descriptor = Object.getOwnPropertyDescriptor(currentProto, method);
|
|
290
|
+
if (descriptor) return descriptor;
|
|
291
|
+
currentProto = Object.getPrototypeOf(currentProto);
|
|
292
|
+
}
|
|
293
|
+
}
|
|
218
294
|
|
|
219
295
|
//#endregion
|
|
220
|
-
//#region ../../node_modules/.pnpm/@vitest+expect@3.
|
|
296
|
+
//#region ../../node_modules/.pnpm/@vitest+expect@3.2.0/node_modules/@vitest/expect/dist/index.js
|
|
221
297
|
const MATCHERS_OBJECT = Symbol.for("matchers-object");
|
|
222
298
|
const JEST_MATCHERS_OBJECT = Symbol.for("$$jest-matchers-object");
|
|
223
299
|
const GLOBAL_EXPECT = Symbol.for("expect-global");
|
|
@@ -383,6 +459,14 @@ function eq(a$1, b, aStack, bStack, customTesters, hasKey$1) {
|
|
|
383
459
|
return numA === numB || Number.isNaN(numA) && Number.isNaN(numB);
|
|
384
460
|
}
|
|
385
461
|
case "[object RegExp]": return a$1.source === b.source && a$1.flags === b.flags;
|
|
462
|
+
case "[object Temporal.Instant]":
|
|
463
|
+
case "[object Temporal.ZonedDateTime]":
|
|
464
|
+
case "[object Temporal.PlainDateTime]":
|
|
465
|
+
case "[object Temporal.PlainDate]":
|
|
466
|
+
case "[object Temporal.PlainTime]":
|
|
467
|
+
case "[object Temporal.PlainYearMonth]":
|
|
468
|
+
case "[object Temporal.PlainMonthDay]": return a$1.equals(b);
|
|
469
|
+
case "[object Temporal.Duration]": return a$1.toString() === b.toString();
|
|
386
470
|
}
|
|
387
471
|
if (typeof a$1 !== "object" || typeof b !== "object") return false;
|
|
388
472
|
if (isDomNode(a$1) && isDomNode(b)) return a$1.isEqualNode(b);
|
|
@@ -530,7 +614,7 @@ function iterableEquality(a$1, b, customTesters = [], aStack = [], bStack = [])
|
|
|
530
614
|
if (!isImmutableList(a$1) && !isImmutableOrderedKeyed(a$1) && !isImmutableOrderedSet(a$1) && !isImmutableRecord(a$1)) {
|
|
531
615
|
const aEntries = Object.entries(a$1);
|
|
532
616
|
const bEntries = Object.entries(b);
|
|
533
|
-
if (!equals(aEntries, bEntries)) return false;
|
|
617
|
+
if (!equals(aEntries, bEntries, filteredCustomTesters)) return false;
|
|
534
618
|
}
|
|
535
619
|
aStack.pop();
|
|
536
620
|
bStack.pop();
|
|
@@ -549,7 +633,7 @@ function isObjectWithKeys(a$1) {
|
|
|
549
633
|
}
|
|
550
634
|
function subsetEquality(object$1, subset, customTesters = []) {
|
|
551
635
|
const filteredCustomTesters = customTesters.filter((t) => t !== subsetEquality);
|
|
552
|
-
const subsetEqualityWithContext = (seenReferences = new WeakMap()) => (object$2, subset$1) => {
|
|
636
|
+
const subsetEqualityWithContext = (seenReferences = /* @__PURE__ */ new WeakMap()) => (object$2, subset$1) => {
|
|
553
637
|
if (!isObjectWithKeys(subset$1)) return void 0;
|
|
554
638
|
return Object.keys(subset$1).every((key) => {
|
|
555
639
|
if (subset$1[key] != null && typeof subset$1[key] === "object") {
|
|
@@ -606,7 +690,7 @@ function getObjectKeys(object$1) {
|
|
|
606
690
|
}
|
|
607
691
|
function getObjectSubset(object$1, subset, customTesters) {
|
|
608
692
|
let stripped = 0;
|
|
609
|
-
const getObjectSubsetWithContext = (seenReferences = new WeakMap()) => (object$2, subset$1) => {
|
|
693
|
+
const getObjectSubsetWithContext = (seenReferences = /* @__PURE__ */ new WeakMap()) => (object$2, subset$1) => {
|
|
610
694
|
if (Array.isArray(object$2)) {
|
|
611
695
|
if (Array.isArray(subset$1) && subset$1.length === object$2.length) return subset$1.map((sub, i) => getObjectSubsetWithContext(seenReferences)(object$2[i], sub));
|
|
612
696
|
} else if (object$2 instanceof Date) return object$2;
|
|
@@ -638,7 +722,7 @@ function getObjectSubset(object$1, subset, customTesters) {
|
|
|
638
722
|
};
|
|
639
723
|
}
|
|
640
724
|
if (!Object.prototype.hasOwnProperty.call(globalThis, MATCHERS_OBJECT)) {
|
|
641
|
-
const globalState = new WeakMap();
|
|
725
|
+
const globalState = /* @__PURE__ */ new WeakMap();
|
|
642
726
|
const matchers = Object.create(null);
|
|
643
727
|
const customEqualityTesters = [];
|
|
644
728
|
const asymmetricMatchers = Object.create(null);
|
|
@@ -947,8 +1031,8 @@ const JestChaiExpect = (chai$1, utils) => {
|
|
|
947
1031
|
"throw",
|
|
948
1032
|
"throws",
|
|
949
1033
|
"Throw"
|
|
950
|
-
].forEach((m
|
|
951
|
-
utils.overwriteMethod(chai$1.Assertion.prototype, m
|
|
1034
|
+
].forEach((m) => {
|
|
1035
|
+
utils.overwriteMethod(chai$1.Assertion.prototype, m, (_super) => {
|
|
952
1036
|
return function(...args) {
|
|
953
1037
|
const promise = utils.flag(this, "promise");
|
|
954
1038
|
const object$1 = utils.flag(this, "object");
|
|
@@ -1093,7 +1177,7 @@ const JestChaiExpect = (chai$1, utils) => {
|
|
|
1093
1177
|
});
|
|
1094
1178
|
def("toBeNaN", function() {
|
|
1095
1179
|
const obj = utils.flag(this, "object");
|
|
1096
|
-
this.assert(Number.isNaN(obj), "expected #{this} to be NaN", "expected #{this} not to be NaN",
|
|
1180
|
+
this.assert(Number.isNaN(obj), "expected #{this} to be NaN", "expected #{this} not to be NaN", NaN, obj);
|
|
1097
1181
|
});
|
|
1098
1182
|
def("toBeUndefined", function() {
|
|
1099
1183
|
const obj = utils.flag(this, "object");
|
|
@@ -1367,14 +1451,7 @@ const JestChaiExpect = (chai$1, utils) => {
|
|
|
1367
1451
|
const results = action === "return" ? spy.mock.results : spy.mock.settledResults;
|
|
1368
1452
|
const result = results[results.length - 1];
|
|
1369
1453
|
const spyName = spy.getMockName();
|
|
1370
|
-
this.assert(
|
|
1371
|
-
condition(spy, value),
|
|
1372
|
-
`expected last "${spyName}" call to ${action} #{exp}`,
|
|
1373
|
-
`expected last "${spyName}" call to not ${action} #{exp}`,
|
|
1374
|
-
value,
|
|
1375
|
-
// for jest compat
|
|
1376
|
-
result === null || result === void 0 ? void 0 : result.value
|
|
1377
|
-
);
|
|
1454
|
+
this.assert(condition(spy, value), `expected last "${spyName}" call to ${action} #{exp}`, `expected last "${spyName}" call to not ${action} #{exp}`, value, result === null || result === void 0 ? void 0 : result.value);
|
|
1378
1455
|
});
|
|
1379
1456
|
});
|
|
1380
1457
|
[{
|
|
@@ -1466,10 +1543,10 @@ const JestChaiExpect = (chai$1, utils) => {
|
|
|
1466
1543
|
};
|
|
1467
1544
|
function ordinalOf(i) {
|
|
1468
1545
|
const j = i % 10;
|
|
1469
|
-
const k
|
|
1470
|
-
if (j === 1 && k
|
|
1471
|
-
if (j === 2 && k
|
|
1472
|
-
if (j === 3 && k
|
|
1546
|
+
const k = i % 100;
|
|
1547
|
+
if (j === 1 && k !== 11) return `${i}st`;
|
|
1548
|
+
if (j === 2 && k !== 12) return `${i}nd`;
|
|
1549
|
+
if (j === 3 && k !== 13) return `${i}rd`;
|
|
1473
1550
|
return `${i}th`;
|
|
1474
1551
|
}
|
|
1475
1552
|
function formatCalls(spy, msg, showActualCall) {
|
|
@@ -1602,7 +1679,7 @@ function cwd() {
|
|
|
1602
1679
|
if (typeof process !== "undefined" && typeof process.cwd === "function") return process.cwd().replace(/\\/g, "/");
|
|
1603
1680
|
return "/";
|
|
1604
1681
|
}
|
|
1605
|
-
const resolve
|
|
1682
|
+
const resolve = function(...arguments_) {
|
|
1606
1683
|
arguments_ = arguments_.map((argument) => normalizeWindowsPath(argument));
|
|
1607
1684
|
let resolvedPath = "";
|
|
1608
1685
|
let resolvedAbsolute = false;
|
|
@@ -1671,7 +1748,7 @@ const isAbsolute = function(p$1) {
|
|
|
1671
1748
|
};
|
|
1672
1749
|
|
|
1673
1750
|
//#endregion
|
|
1674
|
-
//#region ../../node_modules/.pnpm/vitest@3.
|
|
1751
|
+
//#region ../../node_modules/.pnpm/vitest@3.2.0_@types+node@22.15.29_jiti@2.4.2_lightningcss@1.30.1_msw@2.8.7_@types+node@_9eeb862be92f04c38a20bffaf3a72b73/node_modules/vitest/dist/chunks/utils.XdZDrNZV.js
|
|
1675
1752
|
const NAME_WORKER_STATE = "__vitest_worker__";
|
|
1676
1753
|
function getWorkerState() {
|
|
1677
1754
|
const workerState = globalThis[NAME_WORKER_STATE];
|
|
@@ -1720,14 +1797,14 @@ async function waitForImportsToResolve() {
|
|
|
1720
1797
|
}
|
|
1721
1798
|
|
|
1722
1799
|
//#endregion
|
|
1723
|
-
//#region ../../node_modules/.pnpm/vitest@3.
|
|
1800
|
+
//#region ../../node_modules/.pnpm/vitest@3.2.0_@types+node@22.15.29_jiti@2.4.2_lightningcss@1.30.1_msw@2.8.7_@types+node@_9eeb862be92f04c38a20bffaf3a72b73/node_modules/vitest/dist/chunks/_commonjsHelpers.BFTU3MAI.js
|
|
1724
1801
|
var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
|
|
1725
|
-
function getDefaultExportFromCjs
|
|
1726
|
-
return x
|
|
1802
|
+
function getDefaultExportFromCjs(x) {
|
|
1803
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
|
|
1727
1804
|
}
|
|
1728
1805
|
|
|
1729
1806
|
//#endregion
|
|
1730
|
-
//#region ../../node_modules/.pnpm/@vitest+snapshot@3.
|
|
1807
|
+
//#region ../../node_modules/.pnpm/@vitest+snapshot@3.2.0/node_modules/@vitest/snapshot/dist/index.js
|
|
1731
1808
|
const comma = ",".charCodeAt(0);
|
|
1732
1809
|
const chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
1733
1810
|
const intToChar = new Uint8Array(64);
|
|
@@ -2000,7 +2077,7 @@ function resolve$1(input, base) {
|
|
|
2000
2077
|
default: return url.scheme + "//" + url.user + url.host + url.port + url.path + queryHash;
|
|
2001
2078
|
}
|
|
2002
2079
|
}
|
|
2003
|
-
function resolve(input, base) {
|
|
2080
|
+
function resolve$2(input, base) {
|
|
2004
2081
|
if (base && !base.endsWith("/")) base += "/";
|
|
2005
2082
|
return resolve$1(input, base);
|
|
2006
2083
|
}
|
|
@@ -2122,8 +2199,8 @@ var TraceMap = class {
|
|
|
2122
2199
|
this.sources = sources;
|
|
2123
2200
|
this.sourcesContent = sourcesContent;
|
|
2124
2201
|
this.ignoreList = parsed.ignoreList || parsed.x_google_ignoreList || void 0;
|
|
2125
|
-
const from = resolve(sourceRoot || "", stripFilename(mapUrl));
|
|
2126
|
-
this.resolvedSources = sources.map((s) => resolve(s || "", from));
|
|
2202
|
+
const from = resolve$2(sourceRoot || "", stripFilename(mapUrl));
|
|
2203
|
+
this.resolvedSources = sources.map((s) => resolve$2(s || "", from));
|
|
2127
2204
|
const { mappings } = parsed;
|
|
2128
2205
|
if (typeof mappings === "string") {
|
|
2129
2206
|
this._encoded = mappings;
|
|
@@ -2307,7 +2384,7 @@ function parseSingleV8Stack(raw) {
|
|
|
2307
2384
|
if (!file || !lineNumber || !columnNumber) return null;
|
|
2308
2385
|
if (method.startsWith("async ")) method = method.slice(6);
|
|
2309
2386
|
if (file.startsWith("file://")) file = file.slice(7);
|
|
2310
|
-
file = file.startsWith("node:") || file.startsWith("internal:") ? file : resolve
|
|
2387
|
+
file = file.startsWith("node:") || file.startsWith("internal:") ? file : resolve(file);
|
|
2311
2388
|
if (method) method = method.replace(/__vite_ssr_import_\d+__\./g, "");
|
|
2312
2389
|
return {
|
|
2313
2390
|
method,
|
|
@@ -2331,6 +2408,7 @@ function parseStacktrace(stack, options = {}) {
|
|
|
2331
2408
|
const fileUrl = stack$1.file.startsWith("file://") ? stack$1.file : `file://${stack$1.file}`;
|
|
2332
2409
|
const sourceRootUrl = map$1.sourceRoot ? new URL(map$1.sourceRoot, fileUrl) : fileUrl;
|
|
2333
2410
|
file = new URL(source, sourceRootUrl).pathname;
|
|
2411
|
+
if (file.match(/\/\w:\//)) file = file.slice(1);
|
|
2334
2412
|
}
|
|
2335
2413
|
if (shouldFilter(ignoreStackEntries, file)) return null;
|
|
2336
2414
|
if (line != null && column != null) return {
|
|
@@ -2354,14 +2432,14 @@ function parseV8Stacktrace(stack) {
|
|
|
2354
2432
|
function parseErrorStacktrace(e, options = {}) {
|
|
2355
2433
|
if (!e || isPrimitive(e)) return [];
|
|
2356
2434
|
if (e.stacks) return e.stacks;
|
|
2357
|
-
const stackStr = e.stack ||
|
|
2358
|
-
let stackFrames = parseStacktrace(stackStr, options);
|
|
2435
|
+
const stackStr = e.stack || "";
|
|
2436
|
+
let stackFrames = typeof stackStr === "string" ? parseStacktrace(stackStr, options) : [];
|
|
2359
2437
|
if (!stackFrames.length) {
|
|
2360
2438
|
const e_ = e;
|
|
2361
2439
|
if (e_.fileName != null && e_.lineNumber != null && e_.columnNumber != null) stackFrames = parseStacktrace(`${e_.fileName}:${e_.lineNumber}:${e_.columnNumber}`, options);
|
|
2362
2440
|
if (e_.sourceURL != null && e_.line != null && e_._column != null) stackFrames = parseStacktrace(`${e_.sourceURL}:${e_.line}:${e_.column}`, options);
|
|
2363
2441
|
}
|
|
2364
|
-
if (options.frameFilter) stackFrames = stackFrames.filter((f$
|
|
2442
|
+
if (options.frameFilter) stackFrames = stackFrames.filter((f$1) => options.frameFilter(e, f$1) !== false);
|
|
2365
2443
|
e.stacks = stackFrames;
|
|
2366
2444
|
return stackFrames;
|
|
2367
2445
|
}
|
|
@@ -2382,8 +2460,8 @@ try {
|
|
|
2382
2460
|
nodeInspect = false;
|
|
2383
2461
|
}
|
|
2384
2462
|
const { AsymmetricMatcher: AsymmetricMatcher$1, DOMCollection: DOMCollection$1, DOMElement: DOMElement$1, Immutable: Immutable$1, ReactElement: ReactElement$1, ReactTestComponent: ReactTestComponent$1 } = plugins;
|
|
2385
|
-
function getDefaultExportFromCjs(x
|
|
2386
|
-
return x
|
|
2463
|
+
function getDefaultExportFromCjs$1(x) {
|
|
2464
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
|
|
2387
2465
|
}
|
|
2388
2466
|
var jsTokens_1;
|
|
2389
2467
|
var hasRequiredJsTokens;
|
|
@@ -2875,20 +2953,20 @@ function C(n = false) {
|
|
|
2875
2953
|
}
|
|
2876
2954
|
function p(n = false) {
|
|
2877
2955
|
let e = C(n), i = (r, t, c, o) => {
|
|
2878
|
-
let l
|
|
2956
|
+
let l = "", s = 0;
|
|
2879
2957
|
do
|
|
2880
|
-
l
|
|
2958
|
+
l += r.substring(s, o) + c, s = o + t.length, o = r.indexOf(t, s);
|
|
2881
2959
|
while (~o);
|
|
2882
|
-
return l
|
|
2960
|
+
return l + r.substring(s);
|
|
2883
2961
|
}, g = (r, t, c = r) => {
|
|
2884
|
-
let o = (l
|
|
2885
|
-
let s = String(l
|
|
2962
|
+
let o = (l) => {
|
|
2963
|
+
let s = String(l), b = s.indexOf(t, r.length);
|
|
2886
2964
|
return ~b ? r + i(s, t, c, b) + t : r + s + t;
|
|
2887
2965
|
};
|
|
2888
2966
|
return o.open = r, o.close = t, o;
|
|
2889
|
-
}, u$
|
|
2890
|
-
for (let [r, t] of h) u$
|
|
2891
|
-
return u$
|
|
2967
|
+
}, u$1 = { isColorSupported: e }, d = (r) => `\x1B[${r}m`;
|
|
2968
|
+
for (let [r, t] of h) u$1[r] = e ? g(d(t[0]), d(t[1]), t[2]) : a;
|
|
2969
|
+
return u$1;
|
|
2892
2970
|
}
|
|
2893
2971
|
p();
|
|
2894
2972
|
const lineSplitRE = /\r?\n/;
|
|
@@ -3066,7 +3144,7 @@ function requireNaturalCompare() {
|
|
|
3066
3144
|
return naturalCompare$1.exports;
|
|
3067
3145
|
}
|
|
3068
3146
|
var naturalCompareExports = requireNaturalCompare();
|
|
3069
|
-
var naturalCompare = /* @__PURE__ */ getDefaultExportFromCjs(naturalCompareExports);
|
|
3147
|
+
var naturalCompare = /* @__PURE__ */ getDefaultExportFromCjs$1(naturalCompareExports);
|
|
3070
3148
|
const serialize$1 = (val, config, indentation, depth, refs, printer) => {
|
|
3071
3149
|
const name = val.getMockName();
|
|
3072
3150
|
const nameString = name === "vi.fn()" ? "" : ` ${name}`;
|
|
@@ -3216,12 +3294,12 @@ var CounterMap = class extends DefaultMap {
|
|
|
3216
3294
|
total() {
|
|
3217
3295
|
if (typeof this._total !== "undefined") return this._total;
|
|
3218
3296
|
let total = 0;
|
|
3219
|
-
for (const x
|
|
3297
|
+
for (const x of this.values()) total += x;
|
|
3220
3298
|
return total;
|
|
3221
3299
|
}
|
|
3222
3300
|
};
|
|
3223
|
-
function isSameStackPosition(x
|
|
3224
|
-
return x
|
|
3301
|
+
function isSameStackPosition(x, y) {
|
|
3302
|
+
return x.file === y.file && x.column === y.column && x.line === y.line;
|
|
3225
3303
|
}
|
|
3226
3304
|
var SnapshotState = class SnapshotState {
|
|
3227
3305
|
_counters = new CounterMap();
|
|
@@ -3503,7 +3581,7 @@ function createMismatchError(message, expand, actual, expected) {
|
|
|
3503
3581
|
return error;
|
|
3504
3582
|
}
|
|
3505
3583
|
var SnapshotClient = class {
|
|
3506
|
-
snapshotStateMap = new Map();
|
|
3584
|
+
snapshotStateMap = /* @__PURE__ */ new Map();
|
|
3507
3585
|
constructor(options = {}) {
|
|
3508
3586
|
this.options = options;
|
|
3509
3587
|
}
|
|
@@ -3577,11 +3655,11 @@ var SnapshotClient = class {
|
|
|
3577
3655
|
};
|
|
3578
3656
|
|
|
3579
3657
|
//#endregion
|
|
3580
|
-
//#region ../../node_modules/.pnpm/vitest@3.
|
|
3658
|
+
//#region ../../node_modules/.pnpm/vitest@3.2.0_@types+node@22.15.29_jiti@2.4.2_lightningcss@1.30.1_msw@2.8.7_@types+node@_9eeb862be92f04c38a20bffaf3a72b73/node_modules/vitest/dist/chunks/date.Bq6ZW5rf.js
|
|
3581
3659
|
const RealDate = Date;
|
|
3582
3660
|
let now = null;
|
|
3583
3661
|
var MockDate = class MockDate extends RealDate {
|
|
3584
|
-
constructor(y
|
|
3662
|
+
constructor(y, m, d, h$1, M, s, ms) {
|
|
3585
3663
|
super();
|
|
3586
3664
|
let date;
|
|
3587
3665
|
switch (arguments.length) {
|
|
@@ -3590,15 +3668,15 @@ var MockDate = class MockDate extends RealDate {
|
|
|
3590
3668
|
else date = new RealDate();
|
|
3591
3669
|
break;
|
|
3592
3670
|
case 1:
|
|
3593
|
-
date = new RealDate(y
|
|
3671
|
+
date = new RealDate(y);
|
|
3594
3672
|
break;
|
|
3595
3673
|
default:
|
|
3596
|
-
d
|
|
3674
|
+
d = typeof d === "undefined" ? 1 : d;
|
|
3597
3675
|
h$1 = h$1 || 0;
|
|
3598
3676
|
M = M || 0;
|
|
3599
3677
|
s = s || 0;
|
|
3600
3678
|
ms = ms || 0;
|
|
3601
|
-
date = new RealDate(y
|
|
3679
|
+
date = new RealDate(y, m, d, h$1, M, s, ms);
|
|
3602
3680
|
break;
|
|
3603
3681
|
}
|
|
3604
3682
|
Object.setPrototypeOf(date, MockDate.prototype);
|
|
@@ -3626,7 +3704,7 @@ function resetDate() {
|
|
|
3626
3704
|
}
|
|
3627
3705
|
|
|
3628
3706
|
//#endregion
|
|
3629
|
-
//#region ../../node_modules/.pnpm/vitest@3.
|
|
3707
|
+
//#region ../../node_modules/.pnpm/vitest@3.2.0_@types+node@22.15.29_jiti@2.4.2_lightningcss@1.30.1_msw@2.8.7_@types+node@_9eeb862be92f04c38a20bffaf3a72b73/node_modules/vitest/dist/chunks/vi.bdSIJ99Y.js
|
|
3630
3708
|
const unsupported = [
|
|
3631
3709
|
"matchSnapshot",
|
|
3632
3710
|
"toMatchSnapshot",
|
|
@@ -3772,7 +3850,7 @@ function requireChaiSubset() {
|
|
|
3772
3850
|
return chaiSubset$1.exports;
|
|
3773
3851
|
}
|
|
3774
3852
|
var chaiSubsetExports = requireChaiSubset();
|
|
3775
|
-
var Subset = /* @__PURE__ */ getDefaultExportFromCjs
|
|
3853
|
+
var Subset = /* @__PURE__ */ getDefaultExportFromCjs(chaiSubsetExports);
|
|
3776
3854
|
function createAssertionMessage(util, assertion, hasArgs) {
|
|
3777
3855
|
const not = util.flag(assertion, "negate") ? "not." : "";
|
|
3778
3856
|
const name = `${util.flag(assertion, "_name")}(expected)`;
|
|
@@ -3964,23 +4042,12 @@ function createExpect(test$1) {
|
|
|
3964
4042
|
const expect$1 = (value, message) => {
|
|
3965
4043
|
const { assertionCalls } = getState(expect$1);
|
|
3966
4044
|
setState({ assertionCalls: assertionCalls + 1 }, expect$1);
|
|
3967
|
-
const assert$
|
|
4045
|
+
const assert$2 = expect(value, message);
|
|
3968
4046
|
const _test = test$1 || getCurrentTest();
|
|
3969
|
-
if (_test) return assert$
|
|
3970
|
-
else return assert$
|
|
4047
|
+
if (_test) return assert$2.withTest(_test);
|
|
4048
|
+
else return assert$2;
|
|
3971
4049
|
};
|
|
3972
|
-
Object.assign(
|
|
3973
|
-
expect$1,
|
|
3974
|
-
// eslint-disable-line id-blacklist
|
|
3975
|
-
//see https://heycam.github.io/webidl/#abstract-opdef-converttoint
|
|
3976
|
-
// arbitrarily large number to avoid collisions with native timer IDs
|
|
3977
|
-
// [millis, nanoremainder]
|
|
3978
|
-
// eslint-disable-line
|
|
3979
|
-
// const for now
|
|
3980
|
-
// explicitly drop additional arguments
|
|
3981
|
-
// do it all again - for the remainder of the requested range
|
|
3982
|
-
expect
|
|
3983
|
-
);
|
|
4050
|
+
Object.assign(expect$1, expect);
|
|
3984
4051
|
Object.assign(expect$1, globalThis[ASYMMETRIC_MATCHERS_OBJECT]);
|
|
3985
4052
|
expect$1.getState = () => getState(expect$1);
|
|
3986
4053
|
expect$1.setState = (state) => setState(state, expect$1);
|
|
@@ -4127,9 +4194,9 @@ function requireCalledInOrder() {
|
|
|
4127
4194
|
/**
|
|
4128
4195
|
* @private
|
|
4129
4196
|
*/
|
|
4130
|
-
function checkAdjacentCalls(callMap, spy, index, spies) {
|
|
4197
|
+
function checkAdjacentCalls(callMap, spy, index, spies$1) {
|
|
4131
4198
|
var calledBeforeNext = true;
|
|
4132
|
-
if (index !== spies.length - 1) calledBeforeNext = spy.calledBefore(spies[index + 1]);
|
|
4199
|
+
if (index !== spies$1.length - 1) calledBeforeNext = spy.calledBefore(spies$1[index + 1]);
|
|
4133
4200
|
if (hasCallsLeft(callMap, spy) && calledBeforeNext) {
|
|
4134
4201
|
callMap[spy.id] += 1;
|
|
4135
4202
|
return true;
|
|
@@ -4148,9 +4215,9 @@ function requireCalledInOrder() {
|
|
|
4148
4215
|
* @param {SinonProxy[] | SinonProxy} spies An array of proxies, or several proxies as arguments
|
|
4149
4216
|
* @returns {boolean} true when spies are called in order, false otherwise
|
|
4150
4217
|
*/
|
|
4151
|
-
function calledInOrder(spies) {
|
|
4218
|
+
function calledInOrder(spies$1) {
|
|
4152
4219
|
var callMap = {};
|
|
4153
|
-
var _spies = arguments.length > 1 ? arguments : spies;
|
|
4220
|
+
var _spies = arguments.length > 1 ? arguments : spies$1;
|
|
4154
4221
|
return every$1(_spies, checkAdjacentCalls.bind(null, callMap));
|
|
4155
4222
|
}
|
|
4156
4223
|
calledInOrder_1 = calledInOrder;
|
|
@@ -4290,8 +4357,8 @@ function requireOrderByFirstCall() {
|
|
|
4290
4357
|
* @param {SinonProxy[] | SinonProxy} spies
|
|
4291
4358
|
* @returns {SinonProxy[]}
|
|
4292
4359
|
*/
|
|
4293
|
-
function orderByFirstCall(spies) {
|
|
4294
|
-
return sort$1(slice(spies), comparator);
|
|
4360
|
+
function orderByFirstCall(spies$1) {
|
|
4361
|
+
return sort$1(slice(spies$1), comparator);
|
|
4295
4362
|
}
|
|
4296
4363
|
orderByFirstCall_1 = orderByFirstCall;
|
|
4297
4364
|
return orderByFirstCall_1;
|
|
@@ -4378,8 +4445,8 @@ function requireTypeDetect() {
|
|
|
4378
4445
|
var symbolToStringTagExists = symbolExists && typeof Symbol.toStringTag !== "undefined";
|
|
4379
4446
|
var setEntriesExists = setExists && typeof Set.prototype.entries === "function";
|
|
4380
4447
|
var mapEntriesExists = mapExists && typeof Map.prototype.entries === "function";
|
|
4381
|
-
var setIteratorPrototype = setEntriesExists && Object.getPrototypeOf(new Set().entries());
|
|
4382
|
-
var mapIteratorPrototype = mapEntriesExists && Object.getPrototypeOf(new Map().entries());
|
|
4448
|
+
var setIteratorPrototype = setEntriesExists && Object.getPrototypeOf((/* @__PURE__ */ new Set()).entries());
|
|
4449
|
+
var mapIteratorPrototype = mapEntriesExists && Object.getPrototypeOf((/* @__PURE__ */ new Map()).entries());
|
|
4383
4450
|
var arrayIteratorExists = symbolIteratorExists && typeof Array.prototype[Symbol.iterator] === "function";
|
|
4384
4451
|
var arrayIteratorPrototype = arrayIteratorExists && Object.getPrototypeOf([][Symbol.iterator]());
|
|
4385
4452
|
var stringIteratorExists = symbolIteratorExists && typeof String.prototype[Symbol.iterator] === "function";
|
|
@@ -4706,15 +4773,15 @@ function requireFakeTimersSrc() {
|
|
|
4706
4773
|
function parseTime(str) {
|
|
4707
4774
|
if (!str) return 0;
|
|
4708
4775
|
const strings = str.split(":");
|
|
4709
|
-
const l
|
|
4710
|
-
let i = l
|
|
4776
|
+
const l = strings.length;
|
|
4777
|
+
let i = l;
|
|
4711
4778
|
let ms = 0;
|
|
4712
4779
|
let parsed;
|
|
4713
|
-
if (l
|
|
4780
|
+
if (l > 3 || !/^(\d\d:){0,2}\d\d?$/.test(str)) throw new Error("tick only understands numbers, 'm:s' and 'h:m:s'. Each part must be two digits");
|
|
4714
4781
|
while (i--) {
|
|
4715
4782
|
parsed = parseInt(strings[i], 10);
|
|
4716
4783
|
if (parsed >= 60) throw new Error(`Invalid time ${str}`);
|
|
4717
|
-
ms += parsed * Math.pow(60, l
|
|
4784
|
+
ms += parsed * Math.pow(60, l - i - 1);
|
|
4718
4785
|
}
|
|
4719
4786
|
return ms * 1e3;
|
|
4720
4787
|
}
|
|
@@ -5069,10 +5136,10 @@ To automatically clean-up native timers, use \`shouldClearNativeTimers\`.`);
|
|
|
5069
5136
|
* @returns {Timer[]}
|
|
5070
5137
|
*/
|
|
5071
5138
|
function uninstall(clock, config) {
|
|
5072
|
-
let method, i, l
|
|
5139
|
+
let method, i, l;
|
|
5073
5140
|
const installedHrTime = "_hrtime";
|
|
5074
5141
|
const installedNextTick = "_nextTick";
|
|
5075
|
-
for (i = 0, l
|
|
5142
|
+
for (i = 0, l = clock.methods.length; i < l; i++) {
|
|
5076
5143
|
method = clock.methods[i];
|
|
5077
5144
|
if (method === "hrtime" && _global.process) _global.process.hrtime = clock[installedHrTime];
|
|
5078
5145
|
else if (method === "nextTick" && _global.process) _global.process.nextTick = clock[installedNextTick];
|
|
@@ -5571,7 +5638,7 @@ To automatically clean-up native timers, use \`shouldClearNativeTimers\`.`);
|
|
|
5571
5638
|
});
|
|
5572
5639
|
});
|
|
5573
5640
|
};
|
|
5574
|
-
clock.reset = function reset() {
|
|
5641
|
+
clock.reset = function reset$1() {
|
|
5575
5642
|
nanos = 0;
|
|
5576
5643
|
clock.timers = {};
|
|
5577
5644
|
clock.jobs = [];
|
|
@@ -5628,13 +5695,13 @@ To automatically clean-up native timers, use \`shouldClearNativeTimers\`.`);
|
|
|
5628
5695
|
if (config.ignoreMissingTimers) return;
|
|
5629
5696
|
throw new ReferenceError(`non-existent timers and/or objects cannot be faked: '${timer}'`);
|
|
5630
5697
|
}
|
|
5631
|
-
let i, l
|
|
5698
|
+
let i, l;
|
|
5632
5699
|
const clock = createClock(config.now, config.loopLimit);
|
|
5633
5700
|
clock.shouldClearNativeTimers = config.shouldClearNativeTimers;
|
|
5634
5701
|
clock.uninstall = function() {
|
|
5635
5702
|
return uninstall(clock, config);
|
|
5636
5703
|
};
|
|
5637
|
-
clock.abortListenerMap = new Map();
|
|
5704
|
+
clock.abortListenerMap = /* @__PURE__ */ new Map();
|
|
5638
5705
|
clock.methods = config.toFake || [];
|
|
5639
5706
|
if (clock.methods.length === 0) clock.methods = Object.keys(timers);
|
|
5640
5707
|
if (config.shouldAdvanceTime === true) {
|
|
@@ -5658,7 +5725,7 @@ To automatically clean-up native timers, use \`shouldClearNativeTimers\`.`);
|
|
|
5658
5725
|
}
|
|
5659
5726
|
if (_global === globalObject && timersModule) clock.timersModuleMethods = [];
|
|
5660
5727
|
if (_global === globalObject && timersPromisesModule) clock.timersPromisesModuleMethods = [];
|
|
5661
|
-
for (i = 0, l
|
|
5728
|
+
for (i = 0, l = clock.methods.length; i < l; i++) {
|
|
5662
5729
|
const nameOfMethodToReplace = clock.methods[i];
|
|
5663
5730
|
if (!isPresent[nameOfMethodToReplace]) {
|
|
5664
5731
|
handleMissingTimer(nameOfMethodToReplace);
|
|
@@ -6073,8 +6140,8 @@ function createVitest() {
|
|
|
6073
6140
|
global: globalThis,
|
|
6074
6141
|
config: workerState.config.fakeTimers
|
|
6075
6142
|
});
|
|
6076
|
-
const _stubsGlobal = new Map();
|
|
6077
|
-
const _stubsEnv = new Map();
|
|
6143
|
+
const _stubsGlobal = /* @__PURE__ */ new Map();
|
|
6144
|
+
const _stubsEnv = /* @__PURE__ */ new Map();
|
|
6078
6145
|
const _envBooleans = [
|
|
6079
6146
|
"PROD",
|
|
6080
6147
|
"DEV",
|
|
@@ -6189,6 +6256,9 @@ function createVitest() {
|
|
|
6189
6256
|
async importMock(path) {
|
|
6190
6257
|
return _mocker().importMock(path, getImporter("importMock"));
|
|
6191
6258
|
},
|
|
6259
|
+
mockObject(value) {
|
|
6260
|
+
return _mocker().mockObject({ value }).value;
|
|
6261
|
+
},
|
|
6192
6262
|
mocked(item, _options = {}) {
|
|
6193
6263
|
return item;
|
|
6194
6264
|
},
|
|
@@ -6276,4 +6346,4 @@ function getImporter(name) {
|
|
|
6276
6346
|
|
|
6277
6347
|
//#endregion
|
|
6278
6348
|
export { globalExpect };
|
|
6279
|
-
//# sourceMappingURL=vi.
|
|
6349
|
+
//# sourceMappingURL=vi.bdSIJ99Y-BfJr7I2s.js.map
|