mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-09 13:21:42 +00:00
Vitest regression that builds `dist/entry.js` and checks two
structural invariants required for startup to not hang:
1. Zero `async "<path>"() { … }` keys inside any `__esm` definition.
esbuild only emits the `async` form when a module body contains
top-level await; the `__esm` helper at the top of the bundle
does not await nested inits, so any async wrapper participating
in a circular module graph would deadlock the boot
`await Promise.all([…])` in `src/entry.tsx`.
2. No `node_modules/ink/build/index.js` or
`node_modules/ink-text-input/build/index.js` modules. Their
absence is what makes invariant 1 hold today; if a future commit
re-introduces the `ink-text-input` re-export, this test catches
it before the bundle ships.
The test rebuilds the bundle on demand when the source is newer than
`dist/entry.js`, runs in <100ms with no TTY needed, and is hermetic
on a clean checkout.
|
||
|---|---|---|
| .. | ||
| __tests__ | ||
| app | ||
| components | ||
| config | ||
| content | ||
| domain | ||
| hooks | ||
| lib | ||
| protocol | ||
| types | ||
| app.tsx | ||
| banner.ts | ||
| entry.tsx | ||
| gatewayClient.ts | ||
| gatewayTypes.ts | ||
| theme.ts | ||
| types.ts | ||