Skip to content

Commit 53bfa9a

Browse files
committed
test: do not expose history
1 parent 4e1e27e commit 53bfa9a

File tree

2 files changed

+15
-32
lines changed
  • packages

2 files changed

+15
-32
lines changed

packages/apollo-forest-run-benchmark/src/config.ts

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,6 @@ export const CONFIG = {
1111
name: "Enable History with size 1",
1212
description: "History enabled with a size of 1",
1313
options: {
14-
enableHistory: true,
15-
},
16-
},
17-
{
18-
name: "Enable History with size 1",
19-
description: "History enabled with a size of 1",
20-
options: {
21-
enableHistory: true,
22-
defaultHistorySize: 1,
23-
},
24-
},
25-
{
26-
name: "Enable Rich History",
27-
description: "History enabled with rich data snapshots",
28-
options: {
29-
enableHistory: true,
30-
enableRichHistory: true,
3114
defaultHistorySize: 1,
3215
},
3316
},

packages/apollo-forest-run/src/cache/read.ts

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -131,21 +131,21 @@ function readOperation(
131131
// Safeguard: make sure previous state doesn't leak outside write operation
132132
assert(!outputTree?.prev);
133133

134-
if (readState.outputTree.operation.historySize) {
135-
Object.defineProperty(
136-
readState.outputTree.result.data,
137-
OPERATION_HISTORY_SYMBOL,
138-
{
139-
get() {
140-
return readState.outputTree.history.items.sort(
141-
(a, b) => a.timestamp - b.timestamp,
142-
);
143-
},
144-
enumerable: false,
145-
configurable: true,
146-
},
147-
);
148-
}
134+
// if (readState.outputTree.operation.historySize) {
135+
// Object.defineProperty(
136+
// readState.outputTree.result.data,
137+
// OPERATION_HISTORY_SYMBOL,
138+
// {
139+
// get() {
140+
// return readState.outputTree.history.items.sort(
141+
// (a, b) => a.timestamp - b.timestamp,
142+
// );
143+
// },
144+
// enumerable: false,
145+
// configurable: true,
146+
// },
147+
// );
148+
// }
149149
return readState;
150150
}
151151

0 commit comments

Comments
 (0)