MCPcopy
hub / github.com/vitest-dev/vitest / add

Method add

packages/mocker/src/registry.ts:14–17  ·  view source on GitHub ↗
(mock: MockedModule)

Source from the content-addressed store, hash-verified

12 }
13
14 add(mock: MockedModule): void {
15 this.registryByUrl.set(mock.url, mock)
16 this.registryById.set(mock.id, mock)
17 }
18
19 public register(
20 json: MockedModuleSerialized,

Callers 15

registerMethod · 0.95
markReadyMethod · 0.45
warnReloadMethod · 0.45
sendEventToIframeMethod · 0.45
extendFunction · 0.45
safeSendCallFunction · 0.45
BrowserTestRunnerClass · 0.45
spawnMethod · 0.45
snapshotSavedFunction · 0.45
registerMockFunction · 0.45
onFileTransformMethod · 0.45
invalidateTreeMethod · 0.45

Calls 1

setMethod · 0.45

Tested by

no test coverage detected