MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / apply_put_succeeds

Function apply_put_succeeds

nodedb-array/src/sync/apply.rs:329–338  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

327
328 #[test]
329 fn apply_put_succeeds() {
330 let mut engine = MockEngine::new();
331 engine.register_array("a", hlc(100));
332
333 let op = put_op("a", 50, 100);
334 let outcome = apply_op(&mut engine, &op).unwrap();
335 assert_eq!(outcome, ApplyOutcome::Applied);
336 assert_eq!(engine.applied.len(), 1);
337 assert_eq!(engine.invalidated.len(), 1);
338 }
339
340 #[test]
341 fn apply_idempotent_on_replay() {

Callers

nothing calls this directly

Calls 4

apply_opFunction · 0.85
register_arrayMethod · 0.80
hlcFunction · 0.70
put_opFunction · 0.70

Tested by

no test coverage detected