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

Function test_store_save_and_load

atomic-agent/src/turn/session.rs:1106–1118  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1104
1105 #[test]
1106 fn test_store_save_and_load() {
1107 let (_dir, store) = make_store();
1108 let session = make_session();
1109
1110 store.save(&session).unwrap();
1111
1112 let loaded = store.load("sess-abc-123").unwrap();
1113 assert!(loaded.is_some());
1114
1115 let loaded = loaded.unwrap();
1116 assert_eq!(loaded.session_id, "sess-abc-123");
1117 assert_eq!(loaded.agent_name, "claude-code");
1118 }
1119
1120 #[test]
1121 fn test_store_load_nonexistent() {

Callers

nothing calls this directly

Calls 5

make_storeFunction · 0.85
make_sessionFunction · 0.70
unwrapMethod · 0.45
saveMethod · 0.45
loadMethod · 0.45

Tested by

no test coverage detected