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

Function test_output_empty_graph

atomic-core/src/output/repo/content.rs:820–841  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

818
819 #[test]
820 fn test_output_empty_graph() {
821 let graph = AliveGraph::new();
822 let order = OrderResult {
823 sccs: Vec::new(),
824 conflict_tree: Default::default(),
825 cyclic_conflicts: 0,
826 forward_edges: Vec::new(),
827 };
828
829 let changes = MemoryChangeStore::new();
830 let hash_fn = |_: NodeId| None;
831
832 let mut buffer = Vec::new();
833 {
834 let pos = Position::ROOT;
835 let mut writer = ConflictWriter::new(&mut buffer, "test.rs", pos);
836
837 let result = output_graph_content(&changes, hash_fn, &graph, &order, &mut writer);
838 assert!(result.is_ok());
839 }
840 assert!(buffer.is_empty());
841 }
842
843 #[test]
844 fn test_output_single_vertex() {

Callers

nothing calls this directly

Calls 1

output_graph_contentFunction · 0.85

Tested by

no test coverage detected