Skip to content

Commit ac05f9d

Browse files
committed
internal: Add query all bench
1 parent dc5290b commit ac05f9d

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

examples/benchmark/normalizr.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,6 @@ export default function addNormlizrSuite(suite) {
4545
normalize(ProjectSchema, data, [], curState, actionMeta);
4646
curState = { ...initialState, entities: {}, endpoints: {} };
4747
})
48-
.add('infer All', () => {
49-
return new MemoCache().buildQueryKey(AllProjects, [], queryState);
50-
})
5148
.add('denormalizeLong', () => {
5249
return new MemoCache().denormalize(ProjectSchema, result, entities);
5350
})
@@ -74,6 +71,12 @@ export default function addNormlizrSuite(suite) {
7471
memo.query(User, [{ login: 'gnoff' }], githubState);
7572
}
7673
})
74+
.add('infer All', () => {
75+
return new MemoCache().buildQueryKey(AllProjects, [], queryState);
76+
})
77+
.add('query All withCache', () => {
78+
return memo.query(AllProjects, [], queryState);
79+
})
7780
.add('denormalizeLong with mixin Entity', () => {
7881
return new MemoCache().denormalize(ProjectSchemaMixin, result, entities);
7982
})

0 commit comments

Comments
 (0)