MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / test_change_append_contents

Function test_change_append_contents

atomic-core/src/change/change.rs:1385–1392  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1383
1384 #[test]
1385 fn test_change_append_contents() {
1386 let mut change = Change::empty(ChangeHeader::new("Test"));
1387 let pos = change.append_contents(b"Hello");
1388 assert_eq!(pos, 0);
1389 let pos2 = change.append_contents(b" World");
1390 assert_eq!(pos2, 5);
1391 assert_eq!(change.contents, b"Hello World");
1392 }
1393
1394 #[test]
1395 fn test_change_finalize() {

Callers

nothing calls this directly

Calls 1

append_contentsMethod · 0.45

Tested by

no test coverage detected