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

Function apply_rejects_schema_too_new

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

Source from the content-addressed store, hash-verified

363
364 #[test]
365 fn apply_rejects_schema_too_new() {
366 let mut engine = MockEngine::new();
367 engine.register_array("a", hlc(50)); // local schema at ms=50
368 let op = put_op("a", 10, 100); // op schema_hlc at ms=100 > 50
369 let outcome = apply_op(&mut engine, &op).unwrap();
370 assert!(matches!(
371 outcome,
372 ApplyOutcome::Rejected(ApplyRejection::SchemaTooNew { local, op: op_hlc })
373 if local == hlc(50) && op_hlc == hlc(100)
374 ));
375 }
376
377 #[test]
378 fn apply_rejects_invalid_shape() {

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