()
| 679 | |
| 680 | #[test] |
| 681 | fn test_put_and_get_trunk() { |
| 682 | let mut txn = MockCrdtTxn::new(); |
| 683 | let id = TrunkId::new(NodeId::new(1), 0); |
| 684 | let trunk = Trunk::new(id, Inode::new(1), "test.rs".to_string(), None); |
| 685 | |
| 686 | assert!(txn.put_trunk(&trunk).unwrap()); |
| 687 | let retrieved = txn.get_trunk(id).unwrap().unwrap(); |
| 688 | assert_eq!(retrieved.path(), "test.rs"); |
| 689 | } |
| 690 | |
| 691 | #[test] |
| 692 | fn test_has_trunk() { |