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

Function extract_cell_bytes_finds_coord

nodedb-array/src/segment/reader.rs:516–527  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

514
515 #[test]
516 fn extract_cell_bytes_finds_coord() {
517 let s = schema();
518 let sparse = make_sparse(&s, 3);
519 // make_sparse builds one entry at coord (base, base+1) = (3, 4).
520 let coord = vec![CoordValue::Int64(3), CoordValue::Int64(4)];
521 let bytes = extract_cell_bytes(&sparse, &coord).unwrap();
522 assert!(bytes.is_some(), "should find coord (3,4)");
523
524 let absent = vec![CoordValue::Int64(9), CoordValue::Int64(9)];
525 let none = extract_cell_bytes(&sparse, &absent).unwrap();
526 assert!(none.is_none(), "absent coord must return None");
527 }
528
529 #[test]
530 fn extract_cell_bytes_carries_valid_time_bounds() {

Callers

nothing calls this directly

Calls 3

make_sparseFunction · 0.85
extract_cell_bytesFunction · 0.85
schemaFunction · 0.70

Tested by

no test coverage detected