test(tabs): drain activeTabStore notification timer before closing jsdom

This commit is contained in:
bincxz committed 2026-11-23 19:32:51 +08:00
1 parent 9e7909281c
commit b44f3502b9
1 file changed
+1
@@ -39,6 +39,7 @@ function setupDom(t: test.TestContext) {
const root = createRoot(document.getElementById("root")!);
t.after(async () => {
activeTabStore.setActiveTabId("vault");
await new Promise((resolve) => dom.window.setTimeout(resolve, 0));
await act(async () => root.unmount());
dom.window.close();
for (const [key, descriptor] of previous) {