Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/NodeDB-Lab/nodedb
/ roundtrip_basic
Function
roundtrip_basic
nodedb-fts/src/codec/delta.rs:45–50 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
43
44
#[test]
45
fn roundtrip_basic() {
46
let values = vec![3, 7, 10, 15, 100];
47
let deltas = encode(&values);
48
assert_eq!(deltas, vec![3, 4, 3, 5, 85]);
49
assert_eq!(decode(&deltas), values);
50
}
51
52
#[test]
53
fn empty() {
Callers
nothing calls this directly
Calls
1
encode
Function · 0.70
Tested by
no test coverage detected