[test] Double the duration of the performance test.

This commit is contained in:
Revone 2023-10-11 22:30:53 +08:00
parent 28df597297
commit f85073bebe
2 changed files with 2 additions and 2 deletions

View file

@ -22,7 +22,7 @@
"fix:src": "npm run lint:src && npm run format:src",
"fix:test": "npm run lint:test && npm run format:test",
"fix": "npm run fix:src && npm run fix:test",
"update:test-deps": "npm i avl-tree-typed binary-tree-typed bst-typed heap-typed --save-dev",
"update:individuals": "npm i avl-tree-typed binary-tree-typed bst-typed heap-typed --save-dev",
"install:individuals": "npm i avl-tree-typed binary-tree-typed bst-typed deque-typed directed-graph-typed doubly-linked-list-typed graph-typed heap-typed linked-list-typed max-heap-typed max-priority-queue-typed min-heap-typed min-priority-queue-typed priority-queue-typed singly-linked-list-typed stack-typed tree-multiset-typed trie-typed undirected-graph-typed queue-typed --save-dev",
"test": "jest",
"check:deps": "dependency-cruiser src",

View file

@ -349,7 +349,7 @@ describe('DoublyLinkedList Performance Test', () => {
for (let i = 0; i < magnitude.LINEAR; i++) {
list.unshift(i);
}
expect(performance.now() - startPushTime).toBeLessThan(bigO.LINEAR * 10);
expect(performance.now() - startPushTime).toBeLessThan(bigO.LINEAR * 20);
expect(list.length).toBeGreaterThan(0);
const startPopTime = performance.now();