Moving to vitest from jest
#231
Replies: 3 comments 9 replies
-
|
I've heard great things about Vitest and definitely see the appeal. Really appreciate you bringing this up. it's a valuable discussion. It feels like an awesome improvement we should absolutely consider. Maybe we can revisit it after we’ve shipped basic workflow support and improved the DX around our TypeScript types. |
Beta Was this translation helpful? Give feedback.
-
|
closing as resolved in #250 |
Beta Was this translation helpful? Give feedback.
-
|
@myrrakh This is exactly the direction we went with for our multi-agent orchestration. The queue abstraction layer is critical. Our approach (tried Redis, RabbitMQ, BullMQ):
Context passing: We use "pass-only-context" rather than shared memory: interface SubagentContext {
requestId: string;
parentAgentId: string;
conversationHistory: Summary[]; // summarized, not raw
relevantFacts: string[]; // extracted from parent memory
}Key insight from Graphiti — facts > raw memory. Passing full conversation gets expensive ($$$ in tokens). Our open-source orchestrator (github.com/jingchang0623-crypto/openclaw-agent-orchestrator) uses this pattern — TypeScript-first and designed for this exact use case. Happy to share war stories from running 10+ agents across 3 services! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Move to
vitestas core testing framework forVoltAgentWhy
Better feature set
anyanymore (https://vitest.dev/guide/testing-types.html#testing-types)rustmodule tests): (https://vitest.dev/guide/in-source)describe.todo: I see a lot of comments to add tests but no way to surface them (https://vitest.dev/api/#describe-todo)Full list: https://vitest.dev/guide/features
Compatible with
jestvitestwas built to be API compatible withjest(https://vitest.dev/guide/migration.html#jest) and the migration should not be difficult to do.Intertia
The
nodejs&typescriptcommunity seems to be adopting it:ai: https://github.com/vercel/ai/blob/main/packages/ai/vitest.node.config.jshono: https://github.com/honojs/hono/blob/main/vitest.config.tsWhy Not?
Time
This is a non-feature add and more about DX working on the VoltAgent platform.
vitewithoutvitestWe aren't using
vitefor builds and that is one of main reasons to use it (or at least it was!)How
We could achieve this in pieces by creating a project to migrate, and any new packages added can be vitest.
@omeraplak FYI I'm willing to take lead on this too, but will have to be a weekend project for sure.
Beta Was this translation helpful? Give feedback.
All reactions