@rstest/browser 0.9.0 → 0.9.2
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/browser-container/container-static/js/{101.36a8ccdf84.js → 101.82cdbbe145.js} +852 -824
- package/dist/browser-container/container-static/js/101.82cdbbe145.js.LICENSE.txt +1 -0
- package/dist/browser-container/container-static/js/{index.0687a8142a.js → index.602d6770fe.js} +91 -84
- package/dist/browser-container/container-static/js/{lib-react.dcf2a5e57a.js → lib-react.ce60b6aea5.js} +3 -3
- package/dist/browser-container/container-static/js/lib-react.ce60b6aea5.js.LICENSE.txt +1 -0
- package/dist/browser-container/index.html +1 -1
- package/dist/browser.js +1 -1
- package/dist/headedSerialTaskQueue.d.ts +8 -0
- package/dist/hostController.d.ts +16 -0
- package/dist/index.js +219 -47
- package/dist/watchCliShortcuts.d.ts +6 -0
- package/package.json +7 -7
- package/src/headedSerialTaskQueue.ts +19 -0
- package/src/hostController.ts +294 -65
- package/src/watchCliShortcuts.ts +77 -0
- package/dist/browser-container/container-static/js/101.36a8ccdf84.js.LICENSE.txt +0 -1
- package/dist/browser-container/container-static/js/lib-react.dcf2a5e57a.js.LICENSE.txt +0 -1
- /package/dist/{361.js → 323.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
/*! LICENSE: 101.82cdbbe145.js.LICENSE.txt */
|
package/dist/browser-container/container-static/js/{index.0687a8142a.js → index.602d6770fe.js}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
(()=>{
|
|
2
2
|
"use strict";
|
|
3
3
|
var e, t, s, l, r, o, a = {
|
|
4
|
-
|
|
4
|
+
1415 (e, t, s) {
|
|
5
5
|
var l = s(6730);
|
|
6
6
|
let r = "__rstest_dispatch_response__";
|
|
7
7
|
var o = s(8593), a = s(5466), i = s(7603), n = s(162), c = s(2739);
|
|
@@ -79,7 +79,7 @@
|
|
|
79
79
|
}
|
|
80
80
|
};
|
|
81
81
|
var k = s(1668), S = s(5735), F = s(1396), N = s(91), A = s(2604), P = s(8149), M = s(1162), z = s(462);
|
|
82
|
-
let
|
|
82
|
+
let R = {
|
|
83
83
|
iPhoneSE: {
|
|
84
84
|
width: 375,
|
|
85
85
|
height: 667
|
|
@@ -148,7 +148,7 @@
|
|
|
148
148
|
width: 1280,
|
|
149
149
|
height: 800
|
|
150
150
|
}
|
|
151
|
-
},
|
|
151
|
+
}, O = {
|
|
152
152
|
iPhoneSE: "iPhone SE",
|
|
153
153
|
iPhoneXR: "iPhone XR",
|
|
154
154
|
iPhone12Pro: "iPhone 12 Pro",
|
|
@@ -185,10 +185,10 @@
|
|
|
185
185
|
"NestHub",
|
|
186
186
|
"NestHubMax"
|
|
187
187
|
].map((e)=>{
|
|
188
|
-
let t =
|
|
188
|
+
let t = R[e];
|
|
189
189
|
return {
|
|
190
190
|
id: e,
|
|
191
|
-
label:
|
|
191
|
+
label: O[e],
|
|
192
192
|
width: t.width,
|
|
193
193
|
height: t.height
|
|
194
194
|
};
|
|
@@ -2285,21 +2285,21 @@
|
|
|
2285
2285
|
8e3,
|
|
2286
2286
|
16e3,
|
|
2287
2287
|
3e4
|
|
2288
|
-
], eb =
|
|
2288
|
+
], eb = function(e, t, s) {
|
|
2289
2289
|
let l = arguments.length > 3 && void 0 !== arguments[3] && arguments[3], r = arguments.length > 4 ? arguments[4] : void 0, o = new URL("/runner.html", t || window.location.origin);
|
|
2290
2290
|
return o.searchParams.set("testFile", e), s && o.searchParams.set("testNamePattern", s), r && o.searchParams.set("runId", r), l && o.searchParams.set("t", Date.now().toString()), o.toString();
|
|
2291
2291
|
};
|
|
2292
|
-
var
|
|
2293
|
-
let
|
|
2292
|
+
var ek = s(5999);
|
|
2293
|
+
let eS = function() {
|
|
2294
2294
|
for(var e = arguments.length, t = Array(e), s = 0; s < e; s++)t[s] = arguments[s];
|
|
2295
2295
|
window.__RSTEST_BROWSER_OPTIONS__?.debug === !0 && console.log(...t);
|
|
2296
|
-
},
|
|
2296
|
+
}, eF = (e)=>{
|
|
2297
2297
|
try {
|
|
2298
2298
|
return new URL(e.src, window.location.href).searchParams.get("runId") ?? void 0;
|
|
2299
2299
|
} catch {
|
|
2300
2300
|
return;
|
|
2301
2301
|
}
|
|
2302
|
-
},
|
|
2302
|
+
}, eN = (e)=>{
|
|
2303
2303
|
let { options: t, theme: s, setTheme: a } = e, { token: i } = o.A.useToken(), [c, u] = (0, n.useState)([]), [p, h] = (0, n.useState)(null), [f, x] = (0, n.useState)({}), [m, g] = (0, n.useState)({}), [j, v] = (0, n.useState)([]), [y, _] = (0, n.useState)(""), w = (0, n.useRef)(new Map), [C, b] = (0, n.useState)({}), k = (0, n.useCallback)((e)=>{
|
|
2304
2304
|
let s = 5381;
|
|
2305
2305
|
for(let e = 0; e < t.rootPath.length; e++)s = 33 * s ^ t.rootPath.charCodeAt(e);
|
|
@@ -2362,18 +2362,18 @@
|
|
|
2362
2362
|
t.projects,
|
|
2363
2363
|
S
|
|
2364
2364
|
]);
|
|
2365
|
-
let P = (0, n.useCallback)(async (e, s)=>(
|
|
2365
|
+
let P = (0, n.useCallback)(async (e, s)=>(eS("[Container] handleReloadTestFile called:", e, s), h(e), new Promise((l, r)=>{
|
|
2366
2366
|
let o = w.current.get(e);
|
|
2367
2367
|
o && o.reject(Error(`Reload for "${e}" was superseded by a newer request.`)), w.current.set(e, {
|
|
2368
2368
|
resolve: l,
|
|
2369
2369
|
reject: r
|
|
2370
2370
|
});
|
|
2371
2371
|
let a = document.querySelector(`iframe[data-test-file="${e}"]`);
|
|
2372
|
-
if (
|
|
2372
|
+
if (eS("[Container] Found iframe:", a), !a) {
|
|
2373
2373
|
w.current.delete(e), r(Error(`Cannot reload test file "${e}": iframe not found`));
|
|
2374
2374
|
return;
|
|
2375
2375
|
}
|
|
2376
|
-
let i =
|
|
2376
|
+
let i = "function" == typeof globalThis.crypto?.randomUUID ? globalThis.crypto.randomUUID() : `run-${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 10)}`;
|
|
2377
2377
|
b((t)=>({
|
|
2378
2378
|
...t,
|
|
2379
2379
|
[e]: i
|
|
@@ -2391,11 +2391,11 @@
|
|
|
2391
2391
|
[e]: l
|
|
2392
2392
|
};
|
|
2393
2393
|
});
|
|
2394
|
-
let n =
|
|
2395
|
-
|
|
2394
|
+
let n = eb(e, t.runnerUrl, s, !1, i);
|
|
2395
|
+
eS("[Container] Setting iframe.src to:", n), a.src = n;
|
|
2396
2396
|
})), [
|
|
2397
2397
|
t.runnerUrl
|
|
2398
|
-
]), { rpc: M, loading: z, connected:
|
|
2398
|
+
]), { rpc: M, loading: z, connected: R } = ((e, t, s)=>{
|
|
2399
2399
|
let [l, r] = (0, n.useState)(null), [o, a] = (0, n.useState)(!0), [i, c] = (0, n.useState)(!1), d = (0, n.useRef)(e), u = (0, n.useRef)(s), p = (0, n.useRef)(null);
|
|
2400
2400
|
return (0, n.useEffect)(()=>{
|
|
2401
2401
|
d.current = e;
|
|
@@ -2413,16 +2413,16 @@
|
|
|
2413
2413
|
p.current = e = new WebSocket((n = "https:" === window.location.protocol ? "wss:" : "ws:", `${n}//${window.location.hostname}:${t}`));
|
|
2414
2414
|
let h = {
|
|
2415
2415
|
onTestFileUpdate (e) {
|
|
2416
|
-
|
|
2416
|
+
eS("[Container RPC] onTestFileUpdate called:", e), d.current(e);
|
|
2417
2417
|
},
|
|
2418
2418
|
async reloadTestFile (e, t) {
|
|
2419
|
-
|
|
2419
|
+
eS("[Container RPC] reloadTestFile called:", e, t), await u.current?.(e, t);
|
|
2420
2420
|
}
|
|
2421
2421
|
};
|
|
2422
2422
|
e.onopen = ()=>{
|
|
2423
2423
|
if (!o || !e) return;
|
|
2424
|
-
|
|
2425
|
-
let t = (0,
|
|
2424
|
+
eS("[Container] WebSocket connected"), s = 0, c(!0);
|
|
2425
|
+
let t = (0, ek.L)(h, {
|
|
2426
2426
|
post: (t)=>{
|
|
2427
2427
|
e?.readyState === WebSocket.OPEN && e.send(JSON.stringify(t));
|
|
2428
2428
|
},
|
|
@@ -2442,13 +2442,13 @@
|
|
|
2442
2442
|
});
|
|
2443
2443
|
}, e.onclose = ()=>{
|
|
2444
2444
|
if (p.current !== e || !o) return;
|
|
2445
|
-
|
|
2445
|
+
eS("[Container] WebSocket disconnected"), r(null), c(!1);
|
|
2446
2446
|
let t = eC[Math.min(s, eC.length - 1)];
|
|
2447
|
-
|
|
2447
|
+
eS(`[Container] Reconnecting in ${t}ms (attempt ${s + 1})`), s++, l = setTimeout(()=>{
|
|
2448
2448
|
o && i();
|
|
2449
2449
|
}, t);
|
|
2450
2450
|
}, e.onerror = ()=>{
|
|
2451
|
-
o &&
|
|
2451
|
+
o && eS("[Container] WebSocket error");
|
|
2452
2452
|
};
|
|
2453
2453
|
};
|
|
2454
2454
|
return i(), ()=>{
|
|
@@ -2478,15 +2478,23 @@
|
|
|
2478
2478
|
return t;
|
|
2479
2479
|
}), b((e)=>{
|
|
2480
2480
|
let t = {};
|
|
2481
|
-
for (let s of c)t[s.testPath] = e[s.testPath]
|
|
2481
|
+
for (let s of c)e[s.testPath] && (t[s.testPath] = e[s.testPath]);
|
|
2482
2482
|
return t;
|
|
2483
2483
|
});
|
|
2484
2484
|
let e = c.map((e)=>e.testPath);
|
|
2485
2485
|
v((t)=>t.filter((t)=>e.includes(t))), h((t)=>!t && c.length > 0 || t && !e.includes(t) && c.length > 0 ? c[0].testPath : t);
|
|
2486
2486
|
}, [
|
|
2487
2487
|
c
|
|
2488
|
+
]), (0, n.useEffect)(()=>{
|
|
2489
|
+
M && R && M.onRunnerFramesReady(c.map((e)=>e.testPath)).catch((e)=>{
|
|
2490
|
+
eS("[Container RPC] Failed to notify runner frames ready:", e);
|
|
2491
|
+
});
|
|
2492
|
+
}, [
|
|
2493
|
+
M,
|
|
2494
|
+
R,
|
|
2495
|
+
c
|
|
2488
2496
|
]);
|
|
2489
|
-
let
|
|
2497
|
+
let O = (0, n.useCallback)((e)=>"pass" === e ? "pass" : "fail" === e ? "fail" : "skip" === e || "todo" === e ? "skip" : "running", []), U = (0, n.useCallback)((e)=>{
|
|
2490
2498
|
h(e);
|
|
2491
2499
|
}, []), E = (0, n.useCallback)((e, t)=>{
|
|
2492
2500
|
let s = (t.parentNames ?? []).filter(Boolean), l = [
|
|
@@ -2504,7 +2512,7 @@
|
|
|
2504
2512
|
name: t.name,
|
|
2505
2513
|
parentNames: s,
|
|
2506
2514
|
fullName: l,
|
|
2507
|
-
status:
|
|
2515
|
+
status: O(t.status),
|
|
2508
2516
|
filePath: t.testPath || e,
|
|
2509
2517
|
location: t.location
|
|
2510
2518
|
}
|
|
@@ -2512,23 +2520,23 @@
|
|
|
2512
2520
|
};
|
|
2513
2521
|
});
|
|
2514
2522
|
}, [
|
|
2515
|
-
|
|
2523
|
+
O
|
|
2516
2524
|
]), T = (0, n.useCallback)((e)=>{
|
|
2517
|
-
h(e), M &&
|
|
2525
|
+
h(e), M && R && M.rerunTest(e);
|
|
2518
2526
|
}, [
|
|
2519
2527
|
M,
|
|
2520
|
-
|
|
2528
|
+
R
|
|
2521
2529
|
]), B = (0, n.useCallback)((e, t)=>{
|
|
2522
|
-
h(e), M &&
|
|
2530
|
+
h(e), M && R && M.rerunTest(e, t);
|
|
2523
2531
|
}, [
|
|
2524
2532
|
M,
|
|
2525
|
-
|
|
2533
|
+
R
|
|
2526
2534
|
]), I = (0, n.useCallback)(()=>{
|
|
2527
|
-
if (M &&
|
|
2535
|
+
if (M && R) for (let e of c)M.rerunTest(e.testPath);
|
|
2528
2536
|
}, [
|
|
2529
2537
|
c,
|
|
2530
2538
|
M,
|
|
2531
|
-
|
|
2539
|
+
R
|
|
2532
2540
|
]);
|
|
2533
2541
|
(0, n.useEffect)(()=>{
|
|
2534
2542
|
let e = (e)=>{
|
|
@@ -2575,7 +2583,7 @@
|
|
|
2575
2583
|
name: t.name,
|
|
2576
2584
|
parentNames: e,
|
|
2577
2585
|
fullName: r,
|
|
2578
|
-
status:
|
|
2586
|
+
status: O(t.status),
|
|
2579
2587
|
filePath: t.testPath || s,
|
|
2580
2588
|
location: t.location
|
|
2581
2589
|
};
|
|
@@ -2609,7 +2617,7 @@
|
|
|
2609
2617
|
return ev(t) && ey(t, "id") && ey(t, "kind") && ey(t, "method") && ey(t, "testPath") && ey(t, "runId") ? t : null;
|
|
2610
2618
|
})(s);
|
|
2611
2619
|
if (l) {
|
|
2612
|
-
let t, o = (t = l.testPath, Array.from(document.querySelectorAll("iframe[data-test-file]")).find((e)=>e.dataset.testFile === t)), a = o ?
|
|
2620
|
+
let t, o = (t = l.testPath, Array.from(document.querySelectorAll("iframe[data-test-file]")).find((e)=>e.dataset.testFile === t)), a = o ? eF(o) : void 0;
|
|
2613
2621
|
if (!a || l.runId !== a) {
|
|
2614
2622
|
let t, o;
|
|
2615
2623
|
null !== (t = e.source) && "function" == typeof t.postMessage && e.source.postMessage({
|
|
@@ -2631,7 +2639,7 @@
|
|
|
2631
2639
|
}, [
|
|
2632
2640
|
p,
|
|
2633
2641
|
E,
|
|
2634
|
-
|
|
2642
|
+
O,
|
|
2635
2643
|
M
|
|
2636
2644
|
]);
|
|
2637
2645
|
let W = (0, n.useMemo)(()=>{
|
|
@@ -2746,7 +2754,7 @@
|
|
|
2746
2754
|
(0, l.jsx)(V, {
|
|
2747
2755
|
theme: s,
|
|
2748
2756
|
onThemeToggle: a,
|
|
2749
|
-
isConnected:
|
|
2757
|
+
isConnected: R,
|
|
2750
2758
|
token: i,
|
|
2751
2759
|
counts: W
|
|
2752
2760
|
}),
|
|
@@ -2758,7 +2766,7 @@
|
|
|
2758
2766
|
onToggleExpandAll: ()=>{
|
|
2759
2767
|
q.length > 0 && q.every((e)=>j.includes(e)) ? v([]) : v(q);
|
|
2760
2768
|
},
|
|
2761
|
-
onRerun:
|
|
2769
|
+
onRerun: R ? I : void 0,
|
|
2762
2770
|
counts: W,
|
|
2763
2771
|
isRunning: L
|
|
2764
2772
|
}),
|
|
@@ -2774,7 +2782,7 @@
|
|
|
2774
2782
|
rootPath: t.rootPath,
|
|
2775
2783
|
projects: t.projects,
|
|
2776
2784
|
loading: z,
|
|
2777
|
-
connected:
|
|
2785
|
+
connected: R,
|
|
2778
2786
|
openFiles: j,
|
|
2779
2787
|
activeFile: p,
|
|
2780
2788
|
token: i,
|
|
@@ -2814,47 +2822,46 @@
|
|
|
2814
2822
|
!p && (0, l.jsx)(d, {
|
|
2815
2823
|
message: "Select a test file on the left to view its run output"
|
|
2816
2824
|
}),
|
|
2817
|
-
c.map((e)=>
|
|
2818
|
-
|
|
2819
|
-
|
|
2820
|
-
|
|
2821
|
-
|
|
2822
|
-
|
|
2823
|
-
|
|
2824
|
-
|
|
2825
|
-
|
|
2826
|
-
|
|
2827
|
-
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
|
|
2832
|
-
|
|
2833
|
-
|
|
2825
|
+
c.map((e)=>{
|
|
2826
|
+
var s;
|
|
2827
|
+
let r, o, a, n;
|
|
2828
|
+
return r = e.testPath === p, o = C[e.testPath], a = N[e.projectName] ?? em(X.get(e.projectName)), (0, l.jsx)("div", {
|
|
2829
|
+
className: "h-full w-full",
|
|
2830
|
+
style: {
|
|
2831
|
+
display: r ? "block" : "none"
|
|
2832
|
+
},
|
|
2833
|
+
children: (0, l.jsx)(ej, {
|
|
2834
|
+
token: i,
|
|
2835
|
+
selection: a,
|
|
2836
|
+
active: r,
|
|
2837
|
+
onResponsiveResize: "responsive" === a.mode ? (t)=>ee(e.projectName, t) : void 0,
|
|
2838
|
+
"data-testid": "responsive" === a.mode ? "viewport-resizer" : void 0,
|
|
2839
|
+
"data-test-project": e.projectName,
|
|
2840
|
+
"data-test-file": e.testPath,
|
|
2841
|
+
children: (0, l.jsx)("iframe", {
|
|
2834
2842
|
"data-test-file": e.testPath,
|
|
2835
|
-
|
|
2836
|
-
|
|
2837
|
-
|
|
2838
|
-
|
|
2839
|
-
|
|
2840
|
-
|
|
2841
|
-
|
|
2842
|
-
|
|
2843
|
-
|
|
2844
|
-
|
|
2845
|
-
|
|
2846
|
-
|
|
2847
|
-
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
|
|
2851
|
-
|
|
2852
|
-
|
|
2853
|
-
}
|
|
2854
|
-
})
|
|
2843
|
+
title: `Test runner for ${(n = (s = e.testPath).split("/"))[n.length - 1] || s}`,
|
|
2844
|
+
src: o ? eb(e.testPath, t.runnerUrl, void 0, !1, o) : "about:blank",
|
|
2845
|
+
className: "block h-full w-full border-0",
|
|
2846
|
+
style: {
|
|
2847
|
+
background: i.colorBgContainer
|
|
2848
|
+
},
|
|
2849
|
+
onLoad: (s)=>{
|
|
2850
|
+
if (!o) return;
|
|
2851
|
+
let l = s.currentTarget, r = eF(l) ?? o;
|
|
2852
|
+
l.contentWindow && l.contentWindow.postMessage({
|
|
2853
|
+
type: "RSTEST_CONFIG",
|
|
2854
|
+
payload: {
|
|
2855
|
+
...t,
|
|
2856
|
+
testFile: e.testPath,
|
|
2857
|
+
runId: r
|
|
2858
|
+
}
|
|
2859
|
+
}, "*");
|
|
2860
|
+
}
|
|
2855
2861
|
})
|
|
2856
|
-
}
|
|
2857
|
-
})
|
|
2862
|
+
})
|
|
2863
|
+
}, e.testPath);
|
|
2864
|
+
})
|
|
2858
2865
|
]
|
|
2859
2866
|
})
|
|
2860
2867
|
]
|
|
@@ -2863,7 +2870,7 @@
|
|
|
2863
2870
|
]
|
|
2864
2871
|
})
|
|
2865
2872
|
});
|
|
2866
|
-
},
|
|
2873
|
+
}, eA = ()=>{
|
|
2867
2874
|
let e = window.__RSTEST_BROWSER_OPTIONS__, [t, s] = (0, n.useState)("dark"), [r, c] = (0, n.useState)("dark");
|
|
2868
2875
|
(0, n.useEffect)(()=>{
|
|
2869
2876
|
let e = window.matchMedia("(prefers-color-scheme: dark)"), t = (e)=>c(e.matches ? "dark" : "light");
|
|
@@ -2908,20 +2915,20 @@
|
|
|
2908
2915
|
}
|
|
2909
2916
|
},
|
|
2910
2917
|
children: (0, l.jsx)(i.A, {
|
|
2911
|
-
children: (0, l.jsx)(
|
|
2918
|
+
children: (0, l.jsx)(eN, {
|
|
2912
2919
|
options: e,
|
|
2913
2920
|
theme: t,
|
|
2914
2921
|
setTheme: s
|
|
2915
2922
|
})
|
|
2916
2923
|
})
|
|
2917
2924
|
});
|
|
2918
|
-
},
|
|
2925
|
+
}, eP = ()=>{
|
|
2919
2926
|
let e = document.getElementById("root");
|
|
2920
2927
|
e && c.createRoot(e).render((0, l.jsx)(n.StrictMode, {
|
|
2921
|
-
children: (0, l.jsx)(
|
|
2928
|
+
children: (0, l.jsx)(eA, {})
|
|
2922
2929
|
}));
|
|
2923
2930
|
};
|
|
2924
|
-
"loading" === document.readyState ? document.addEventListener("DOMContentLoaded",
|
|
2931
|
+
"loading" === document.readyState ? document.addEventListener("DOMContentLoaded", eP) : eP();
|
|
2925
2932
|
}
|
|
2926
2933
|
}, i = {};
|
|
2927
2934
|
function n(e) {
|
|
@@ -2992,6 +2999,6 @@
|
|
|
2992
2999
|
var c = n.O(void 0, [
|
|
2993
3000
|
"783",
|
|
2994
3001
|
"101"
|
|
2995
|
-
], ()=>n(
|
|
3002
|
+
], ()=>n(1415));
|
|
2996
3003
|
c = n.O(c);
|
|
2997
3004
|
})();
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
/*! LICENSE: lib-react.
|
|
1
|
+
/*! LICENSE: lib-react.ce60b6aea5.js.LICENSE.txt */
|
|
2
|
+
/*! LICENSE: lib-react.ce60b6aea5.js.LICENSE.txt */ "use strict";
|
|
3
3
|
(self.rspackChunk_rstest_browser_ui = self.rspackChunk_rstest_browser_ui || []).push([
|
|
4
4
|
[
|
|
5
5
|
"783"
|
|
@@ -5751,7 +5751,7 @@
|
|
|
5751
5751
|
}
|
|
5752
5752
|
iu = t.return;
|
|
5753
5753
|
}
|
|
5754
|
-
}(e, t
|
|
5754
|
+
}(e, t);
|
|
5755
5755
|
} finally{
|
|
5756
5756
|
iM = o, F.p = l, D.T = r;
|
|
5757
5757
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
/*! LICENSE: lib-react.ce60b6aea5.js.LICENSE.txt */
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<script>
|
|
13
13
|
window.__RSTEST_BROWSER_OPTIONS__ = __RSTEST_OPTIONS_PLACEHOLDER__;
|
|
14
14
|
</script>
|
|
15
|
-
<script defer src="/container-static/js/lib-react.
|
|
15
|
+
<script defer src="/container-static/js/lib-react.ce60b6aea5.js"></script><script defer src="/container-static/js/101.82cdbbe145.js"></script><script defer src="/container-static/js/index.602d6770fe.js"></script><link href="/container-static/css/index.5c72297783.css" rel="stylesheet"></head>
|
|
16
16
|
<body>
|
|
17
17
|
<div id="root"></div>
|
|
18
18
|
</body>
|
package/dist/browser.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DISPATCH_RESPONSE_TYPE, DISPATCH_METHOD_RPC, DISPATCH_RPC_REQUEST_TYPE, DISPATCH_MESSAGE_TYPE, DISPATCH_NAMESPACE_BROWSER } from "./
|
|
1
|
+
import { DISPATCH_RESPONSE_TYPE, DISPATCH_METHOD_RPC, DISPATCH_RPC_REQUEST_TYPE, DISPATCH_MESSAGE_TYPE, DISPATCH_NAMESPACE_BROWSER } from "./323.js";
|
|
2
2
|
const DEFAULT_RPC_TIMEOUT_MS = 30000;
|
|
3
3
|
const getRpcTimeout = ()=>window.__RSTEST_BROWSER_OPTIONS__?.rpcTimeout ?? DEFAULT_RPC_TIMEOUT_MS;
|
|
4
4
|
const pendingRequests = new Map();
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export type HeadedSerialTask = () => Promise<void>;
|
|
2
|
+
/**
|
|
3
|
+
* Serializes headed browser file execution so only one task runs at a time.
|
|
4
|
+
* The queue keeps draining even if an earlier task rejects.
|
|
5
|
+
*/
|
|
6
|
+
export declare const createHeadedSerialTaskQueue: () => {
|
|
7
|
+
enqueue: (task: HeadedSerialTask) => Promise<void>;
|
|
8
|
+
};
|
package/dist/hostController.d.ts
CHANGED
|
@@ -1,4 +1,19 @@
|
|
|
1
1
|
import { type BrowserTestRunOptions, type BrowserTestRunResult, type ListCommandResult, type Rstest } from '@rstest/core/browser';
|
|
2
|
+
type LazyCompilationModule = {
|
|
3
|
+
nameForCondition?: () => string | null | undefined;
|
|
4
|
+
};
|
|
5
|
+
type BrowserLazyCompilationConfig = {
|
|
6
|
+
imports: true;
|
|
7
|
+
entries: false;
|
|
8
|
+
test?: (module: LazyCompilationModule) => boolean;
|
|
9
|
+
};
|
|
10
|
+
export declare const createBrowserLazyCompilationConfig: (setupFiles: string[]) => BrowserLazyCompilationConfig;
|
|
11
|
+
export declare const createBrowserRsbuildDevConfig: (isWatchMode: boolean) => {
|
|
12
|
+
hmr: boolean;
|
|
13
|
+
client: {
|
|
14
|
+
logLevel: "error";
|
|
15
|
+
};
|
|
16
|
+
};
|
|
2
17
|
export declare const runBrowserController: (context: Rstest, options?: BrowserTestRunOptions) => Promise<BrowserTestRunResult | void>;
|
|
3
18
|
/**
|
|
4
19
|
* Result from collecting browser tests.
|
|
@@ -19,3 +34,4 @@ export declare const listBrowserTests: (context: Rstest, options?: {
|
|
|
19
34
|
entries: Record<string, string>;
|
|
20
35
|
}>;
|
|
21
36
|
}) => Promise<ListBrowserTestsResult>;
|
|
37
|
+
export {};
|