mirror of
https://github.com/zrwusa/data-structure-typed.git
synced 2024-11-23 12:54:04 +00:00
release: 1.49.1
This commit is contained in:
parent
e113a99b26
commit
4d88405ac1
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "data-structure-typed",
|
||||
"version": "1.49.0",
|
||||
"version": "1.49.1",
|
||||
"description": "Data Structures of Javascript & TypeScript. Heap, Binary Tree, Red Black Tree, Linked List, Deque, Trie, HashMap, Directed Graph, Undirected Graph, Binary Search Tree(BST), AVL Tree, Priority Queue, Graph, Queue, Tree Multiset, Singly Linked List, Doubly Linked List, Max Heap, Max Priority Queue, Min Heap, Min Priority Queue, Stack. Benchmark compared with C++ STL. API aligned with ES6 and Java.util. Usability is comparable to Python",
|
||||
"main": "dist/cjs/index.js",
|
||||
"module": "dist/mjs/index.js",
|
||||
|
|
|
@ -689,8 +689,7 @@ describe('DirectedGraph getCycles', () => {
|
|||
graph.addEdge('E', 'B');
|
||||
const cycles = graph.getCycles();
|
||||
expect(cycles.size).toBe(1);
|
||||
|
||||
console.log(Array.from(cycles.values()));
|
||||
expect(cycles.get(2)).toEqual( [{"key": "B", "value": undefined}, {"key": "D", "value": undefined}, {"key": "E", "value": undefined}]);
|
||||
})
|
||||
})
|
||||
|
||||
|
|
|
@ -278,6 +278,7 @@ describe('UndirectedGraph getCycles', () => {
|
|||
graph.addEdge('E', 'B');
|
||||
const cycles = graph.getCycles();
|
||||
expect(cycles.size).toBe(2);
|
||||
console.log(Array.from(cycles.values()));
|
||||
expect(cycles.get(1)).toEqual([{"key": "A", "value": "A"}, {"key": "B", "value": "B"}, {"key": "D", "value": "D"}, {"key": "C", "value": "C"}]);
|
||||
expect(cycles.get(2)).toEqual([{"key": "B", "value": "B"}, {"key": "D", "value": "D"}, {"key": "E", "value": "E"}]);
|
||||
})
|
||||
})
|
Loading…
Reference in a new issue