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

Function collections_isolated

nodedb/src/engine/sparse/inverted/tests.rs:111–123  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

109
110#[test]
111fn collections_isolated() {
112 let (idx, _dir) = open_temp();
113 idx.index_document(T, "col_a", Surrogate::new(1), "alpha bravo charlie")
114 .unwrap();
115 idx.index_document(T, "col_b", Surrogate::new(1), "delta echo foxtrot")
116 .unwrap();
117
118 let results = idx.search(T, "col_a", "alpha", 10, false, None).unwrap();
119 assert_eq!(results.len(), 1);
120
121 let results = idx.search(T, "col_b", "alpha", 10, false, None).unwrap();
122 assert!(results.is_empty());
123}
124
125#[test]
126fn purge_tenant_structurally_drops_data() {

Callers

nothing calls this directly

Calls 3

open_tempFunction · 0.70
index_documentMethod · 0.45
searchMethod · 0.45

Tested by

no test coverage detected