MCPcopy
hub / github.com/mongodb/node-mongodb-native / testListShift

Function testListShift

test/benchmarks/unitBench/list.bench.js:43–55  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

41};
42
43const testListShift = () => {
44 const bigList = new List();
45 bigList.pushMany(makeBigArray());
46 const h = createHistogram();
47 for (let runs = 0; runs < iterations; runs++) {
48 h.recordDelta();
49 while (bigList.length) bigList.shift();
50 h.recordDelta();
51 bigList.pushMany(makeBigArray());
52 }
53
54 printHistogram(`shift(${defaultItemsSize}) from List`, h);
55};
56
57const testDenqueShift = () => {
58 const Denque = require('denque');

Callers 1

mainFunction · 0.85

Calls 4

pushManyMethod · 0.95
shiftMethod · 0.95
makeBigArrayFunction · 0.85
printHistogramFunction · 0.85

Tested by

no test coverage detected