MCPcopy Create free account
hub / github.com/douchuan/algorithm / non_recursive_dfs

Function non_recursive_dfs

tests/test_undirected_graph.rs:61–66  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

59
60#[test]
61fn non_recursive_dfs() {
62 let graph = create_graph(TINY_G);
63 let dfs = NonRecursiveDFS::new(graph.as_ref(), 0);
64 assert!(vec![1, 2, 3, 4, 5, 6].iter().all(|&w| dfs.marked(w)));
65 assert!(vec![7, 8, 9, 10, 11, 12].iter().all(|&w| !dfs.marked(w)));
66}
67
68#[test]
69fn dfs_paths() {

Callers

nothing calls this directly

Calls 1

create_graphFunction · 0.70

Tested by

no test coverage detected