test(wasm): Tier B headless smoke — run the REAL wasm-visor blob under Node (no browser) - #3638
Merged
Merged
Conversation
…r Node (no browser) The compile-check lane can't catch runtime-only breakage in the browser edge (boot-glue regressions, carrier selection, /api dispatch). This runs the actual compiled js/wasm binary headlessly: - scripts/wasm-headless/localdmsg: self-contained loopback dmsg server (unified TCP+WS, in-memory discovery) printing SEEDPK/SEEDWS/READY and serving until stdin closes. - scripts/wasm-headless/harness.mjs: Node (>=22, global WebSocket — the ONLY browser global the critical path needs) executes Go's wasm_exec.js + build/wasm-visor-go/wasm-visor.wasm, calls skywireVisor.boot against the loopback seed, and asserts boot → ws dmsg session → dmsg_connected → the in-wasm hypervisor /api core answering (/api/about). - scripts/wasm-headless/run.sh + `make test-wasm-headless`: build-if-stale, start helper, run harness, reap deterministically. - .github/workflows/test.yml: new `wasm-headless` job (setup-go + node 22). Validated locally: the real blob boots under Node, joins dmsg over ws, starts the in-process skychat app, and serves /api — PASS in ~30s. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XzckVqHX624RpdEWcvVosA
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Tier B of the wasm-visor test plan: the compile-check lane can't catch runtime-only breakage in the browser edge (boot-glue regressions, carrier selection,
/apidispatch). This job executes the actual compiled js/wasm binary headlessly:scripts/wasm-headless/localdmsg— self-contained loopback dmsg server (unified TCP+WS, in-memory discovery); printsSEEDPK/SEEDWS/READY, serves until stdin closes.scripts/wasm-headless/harness.mjs— Node ≥22 (globalWebSocketis the only browser global the critical path needs) runs Go'swasm_exec.js+wasm-visor.wasm, callsskywireVisor.bootagainst the loopback seed, and asserts boot → ws dmsg session →dmsg_connected→ in-wasm hypervisor/apicore answering.make test-wasm-headless+ a newwasm-headlessCI job (setup-go + node 22).Validated locally: the real blob boots under Node, joins dmsg over ws, starts the in-process skychat app, and serves
/api— PASS in ~30s, twice.Together with #3637 (Tier A native harness + wss deployment probe) this gives the wasm visor a layered regression gate: native logic tests (fast, gating) → real-blob runtime smoke (this) → the live-deployment wss probe (scheduled).