summaryrefslogtreecommitdiffstats
path: root/packages/meshbay-hub/tests/harness/window_leak.mjs
diff options
context:
space:
mode:
authorChristophe Besson <cbesson@gmail.com>2026-08-22 11:50:35 +0200
committerChristophe Besson <cbesson@gmail.com>2026-08-22 11:50:35 +0200
commit79130a9d4eb95db35b1d84f14f9b1b18d18299a7 (patch)
tree5e9f4a68178a0d41a263d26e063b313ca076a68e /packages/meshbay-hub/tests/harness/window_leak.mjs
parent36fde6583bef6b455d2217d65eaaee2f66c08e81 (diff)
downloadmeshbay-79130a9d4eb95db35b1d84f14f9b1b18d18299a7.tar.gz
fix: update source-reading tests that drifted from the code
- test_transport_contracts: CreateGroupPage was refactored into a routing wrapper; assertions now read CreateGroupFormSimple - test_task_lifetime: _spawn now uses an _on_done wrapper instead of a bare self._tasks.discard callback; assertion checks both parts - test_video_buffer_ceiling: target the real updateend handler, not the settled() utility; add awaitingInitRef to the MSE harness scope - test_video_seek: silence debug console.log in window_leak harness so it does not pollute the JSON output Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat (limited to 'packages/meshbay-hub/tests/harness/window_leak.mjs')
-rw-r--r--packages/meshbay-hub/tests/harness/window_leak.mjs4
1 files changed, 3 insertions, 1 deletions
diff --git a/packages/meshbay-hub/tests/harness/window_leak.mjs b/packages/meshbay-hub/tests/harness/window_leak.mjs
index ae6d46e..d5185de 100644
--- a/packages/meshbay-hub/tests/harness/window_leak.mjs
+++ b/packages/meshbay-hub/tests/harness/window_leak.mjs
@@ -43,6 +43,8 @@ const flushQueue = () => {};
const gekRef = { current: null };
const window_ = { MeshBayCrypto: { decryptChunkBin: async () => new Uint8Array(4) } };
+const silentConsole = { log() {}, warn() {}, error() {} };
+
const handler = new Function(
'msg', 'cancelled', 'awaitingInitRef', 'outstandingRef', 'queueRef',
'entry', 'gekRef', 'pump', 'flushQueue', 'console', 'window',
@@ -52,7 +54,7 @@ const deliver = (n) => Promise.all(
Array.from({ length: n }, (_, i) => handler(
{ file_id: entry.id, segment_index: i, nonce: 'n', ct: 'c' },
cancelled, awaitingInitRef, outstandingRef, queueRef, entry, gekRef,
- pump, flushQueue, console, window_)));
+ pump, flushQueue, silentConsole, window_)));
const run = async () => {
// The whole window arrives while reinitAt is still awaiting its updateends.