MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / test_graph_index_operator

Function test_graph_index_operator

atomic-core/src/output/alive/graph.rs:558–571  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

556
557 #[test]
558 fn test_graph_index_operator() {
559 let mut graph = AliveGraph::new();
560 graph.push_vertex(AliveVertex::DUMMY);
561
562 let v = GraphNode::new(
563 NodeId::new(1),
564 ChangePosition::new(0),
565 ChangePosition::new(10),
566 );
567 graph.push_vertex(AliveVertex::new(v));
568
569 assert!(graph[VertexId::DUMMY].is_dummy());
570 assert_eq!(graph[VertexId::new(1)].len(), 10);
571 }
572
573 #[test]
574 fn test_graph_index_mut_operator() {

Callers

nothing calls this directly

Calls 1

push_vertexMethod · 0.80

Tested by

no test coverage detected