Skip to content

Commit

Permalink
Fix comments still mentioning cache.gc({ preserveCanon }).
Browse files Browse the repository at this point in the history
  • Loading branch information
benjamn committed Jun 28, 2021
1 parent be7199b commit 9d8c3f3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/cache/inmemory/__tests__/cache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1378,7 +1378,7 @@ describe('Cache', () => {
expect(originalWriter).not.toBe(cache["storeWriter"]);
expect(originalMBW).not.toBe(cache["maybeBroadcastWatch"]);
// The cache.storeReader.canon is preserved by default, but can be dropped
// by passing preserveCanon:false to cache.gc.
// by passing resetResultIdentities:true to cache.gc.
expect(originalCanon).toBe(cache["storeReader"].canon);
});
});
Expand Down
4 changes: 2 additions & 2 deletions src/cache/inmemory/__tests__/entityStore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -220,8 +220,8 @@ describe('EntityStore', () => {
const resultAfterFullGC = cache.readQuery({ query });
expect(resultAfterFullGC).toEqual(resultBeforeGC);
expect(resultAfterFullGC).toEqual(resultAfterGC);
// These !== relations are triggered by the preserveCanon:false option
// passed to cache.gc, above.
// These !== relations are triggered by passing resetResultIdentities:true
// to cache.gc, above.
expect(resultAfterFullGC).not.toBe(resultBeforeGC);
expect(resultAfterFullGC).not.toBe(resultAfterGC);
// Result caching immediately begins working again after the intial reset.
Expand Down

0 comments on commit 9d8c3f3

Please sign in to comment.