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

Function test_mark_branch_deleted

atomic-core/src/crdt/apply/traits.rs:904–914  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

902
903 #[test]
904 fn test_mark_branch_deleted() {
905 let mut txn = MockCrdtTxn::new();
906 let trunk_id = TrunkId::new(NodeId::new(1), 0);
907 let branch_id = BranchId::new(NodeId::new(1), 0);
908
909 txn.create_branch(branch_id, trunk_id, None).unwrap();
910 txn.mark_branch_deleted(branch_id).unwrap();
911
912 let branch = txn.get_branch(branch_id).unwrap().unwrap();
913 assert!(branch.state().is_deleted());
914 }
915
916 #[test]
917 fn test_create_leaf() {

Callers

nothing calls this directly

Calls 4

create_branchMethod · 0.80
mark_branch_deletedMethod · 0.80
unwrapMethod · 0.45
get_branchMethod · 0.45

Tested by

no test coverage detected