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

Function test_postcard_is_compact

atomic-core/src/change/session.rs:1398–1409  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1396
1397 #[test]
1398 fn test_postcard_is_compact() {
1399 // Verify that postcard produces reasonably compact output.
1400 // An IntentEntry with short strings should fit in well under 200 bytes.
1401 let entry = sample_intent_entry();
1402 let bytes = entry.to_bytes();
1403
1404 assert!(
1405 bytes.len() < 200,
1406 "expected compact serialization, got {} bytes",
1407 bytes.len()
1408 );
1409 }
1410
1411 #[test]
1412 fn test_session_record_roundtrip() {

Callers

nothing calls this directly

Calls 2

sample_intent_entryFunction · 0.85
to_bytesMethod · 0.45

Tested by

no test coverage detected