We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6b9a1b5 commit b27e002Copy full SHA for b27e002
packages/vitest/src/runtime/moduleRunner/startModuleRunner.ts
@@ -128,6 +128,12 @@ export function startVitestModuleRunner(options: ContextModuleRunnerOptions): Vi
128
return { externalize: toBuiltin(rawId), type: 'builtin' }
129
}
130
131
+ // if module is invalidated, the worker will be recreated,
132
+ // so cached is always true in a single worker
133
+ if (options?.cached) {
134
+ return { cache: true }
135
+ }
136
+
137
const otelCarrier = traces?.getContextCarrier()
138
const result = await rpc().fetch(
139
id,
0 commit comments