MCPcopy Create free account
hub / github.com/ChromeDevTools/devtools-frontend / stub

Function stub

front_end/testing/TrackAsyncOperations.ts:287–290  ·  view source on GitHub ↗
(name: T)

Source from the content-addressed store, hash-verified

285
286const stubs = new Set<TrackedAsyncOperation>();
287function stub<T extends TrackedAsyncOperation>(name: T) {
288 (window[name] as unknown) = stubMethods[name];
289 stubs.add(name);
290}
291
292function restoreAll() {
293 for (const name of stubs) {

Callers 1

Calls 1

addMethod · 0.45

Tested by

no test coverage detected