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

Function test_manifest_json_roundtrip

atomic-remote/src/streaming/tests.rs:310–319  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

308
309#[test]
310fn test_manifest_json_roundtrip() {
311 let manifest = ChunkManifest::new(vec![
312 ChunkManifestEntry::new(0, [0xAA; 32], 32000, 65536),
313 ChunkManifestEntry::new(1, [0xBB; 32], 28000, 65536),
314 ]);
315
316 let json = serde_json::to_string(&manifest).unwrap();
317 let decoded: ChunkManifest = serde_json::from_str(&json).unwrap();
318 assert_eq!(manifest, decoded);
319}
320
321// ── ChunkNegotiation ───────────────────────────────────────────
322

Callers

nothing calls this directly

Calls 1

unwrapMethod · 0.45

Tested by

no test coverage detected