mirror of
https://github.com/Kpa-clawbot/meshcore-analyzer.git
synced 2026-05-31 20:14:40 +00:00
## Root cause `makeLiveSandbox()` in `test-live.js` didn't load `public/packet-helpers.js`, so `window.getParsedDecoded` / `getParsedPath` were undefined. The `dbPacketToLive` and `expandToBufferEntries` suites failed all 8 assertions with `getParsedDecoded is not a function`. The `expandToBufferEntriesAsync` suite was unaffected because it builds its sandbox manually and already loads packet-helpers.js. ## Fix - `test-live.js`: load `public/packet-helpers.js` in `makeLiveSandbox()` before `live.js`. Mirrors the working pattern in `expandToBufferEntriesAsync`. - `.github/workflows/deploy.yml`: wire `node test-live.js` into the "Run JS unit tests" step so this can't silently regress again. - Adjusted one cross-realm `deepStrictEqual([], [])` → `.length === 0` because the array literal lives inside the vm sandbox; host-side `deepStrictEqual` rejects the proto mismatch even when the value is semantically equal. Test-harness only. No production code change. ## Mutation verification With the new `loadInCtx(ctx, 'public/packet-helpers.js')` line removed, all 8 original assertions return (`getParsedDecoded is not a function`). With the fix in place, `node test-live.js` exits 0 — 95 passed, 0 failed. ## CI wire `node test-live.js` now runs in deploy.yml under "Run JS unit tests (packet-filter)" alongside the other root-level test files. YAML validated with `yaml.safe_load`. Fixes #1392 Co-authored-by: openclaw-bot <bot@openclaw.dev>
This commit is contained in:
@@ -111,6 +111,7 @@ jobs:
|
||||
node test-issue-1364-pill-no-clamp.js
|
||||
node test-issue-1375-scope-stats-fetch.js
|
||||
node test-issue-1361-cb-presets.js
|
||||
node test-live.js
|
||||
|
||||
- name: 🧹 Frontend lint (eslint no-undef) — issue #1342
|
||||
run: |
|
||||
|
||||
Reference in New Issue
Block a user