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

Function test_leaf_id_serde

atomic-core/src/crdt/ids.rs:446–451  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

444
445 #[test]
446 fn test_leaf_id_serde() {
447 let id = LeafId::new(NodeId::new(100), 7);
448 let json = serde_json::to_string(&id).unwrap();
449 let decoded: LeafId = serde_json::from_str(&json).unwrap();
450 assert_eq!(id, decoded);
451 }
452
453 // -------------------------------------------------------------------------
454 // Cross-type Tests

Callers

nothing calls this directly

Calls 1

unwrapMethod · 0.45

Tested by

no test coverage detected