()
| 915 | |
| 916 | #[test] |
| 917 | fn test_create_leaf() { |
| 918 | let mut txn = MockCrdtTxn::new(); |
| 919 | let branch_id = BranchId::new(NodeId::new(1), 0); |
| 920 | let leaf_id = LeafId::new(NodeId::new(1), 0); |
| 921 | |
| 922 | let leaf = txn |
| 923 | .create_leaf(leaf_id, branch_id, TokenKind::Word, 0..5, None) |
| 924 | .unwrap(); |
| 925 | |
| 926 | assert_eq!(leaf.id(), leaf_id); |
| 927 | assert_eq!(leaf.branch(), branch_id); |
| 928 | assert_eq!(leaf.kind(), TokenKind::Word); |
| 929 | assert!(txn.has_leaf(leaf_id).unwrap()); |
| 930 | } |
| 931 | |
| 932 | #[test] |
| 933 | fn test_mark_leaf_deleted() { |
nothing calls this directly
no test coverage detected