()
| 870 | |
| 871 | #[test] |
| 872 | fn test_apply_replace_not_found() { |
| 873 | let mut txn = MockTxn::new(); |
| 874 | let mut context = ApplyContext::new(ApplyOptions::default()); |
| 875 | let branch_id = BranchId::new(NodeId::new(1), 0); |
| 876 | let leaf_id = LeafId::new(NodeId::new(1), 0); |
| 877 | |
| 878 | let op = LeafOp::Replace { |
| 879 | leaf: leaf_id, |
| 880 | new_content: b"world".to_vec(), |
| 881 | }; |
| 882 | let result = apply_leaf_op(&mut txn, &mut context, branch_id, leaf_id, &op, b"world"); |
| 883 | |
| 884 | assert!(result.is_err()); |
| 885 | assert!(result.unwrap_err().is_not_found()); |
| 886 | } |
| 887 | |
| 888 | #[test] |
| 889 | fn test_apply_replace_deleted() { |
nothing calls this directly
no test coverage detected