MCPcopy
hub / github.com/jestjs/jest / clear

Method clear

packages/jest-snapshot/src/State.ts:138–147  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

136 }
137
138 clear(): void {
139 this._snapshotData = this._initialData;
140 this._inlineSnapshots = [];
141 this._counters = new Map();
142 this._index = 0;
143 this.added = 0;
144 this.matched = 0;
145 this.unmatched = 0;
146 this.updated = 0;
147 }
148
149 save(): SaveStatus {
150 const hasExternalSnapshots = Object.keys(this._snapshotData).length;

Callers 9

__setMockFilesFunction · 0.45
__setMockFilesFunction · 0.45
collectHandlesFunction · 0.45
clearAllTimersMethod · 0.45
onEndMethod · 0.45
removeUncheckedKeysMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected