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

Function create_test_change

atomic-core/src/change/store.rs:532–537  ·  view source on GitHub ↗
(message: &str, content: &[u8])

Source from the content-addressed store, hash-verified

530 use crate::types::ChangePosition;
531
532 fn create_test_change(message: &str, content: &[u8]) -> Change {
533 let mut change = Change::empty(ChangeHeader::new(message));
534 change.contents = content.to_vec();
535 change.finalize();
536 change
537 }
538
539 // ------------------------------------------------------------------------
540 // MemoryStoreError Tests

Callers 15

test_insert_and_getFunction · 0.70
test_removeFunction · 0.70
test_clearFunction · 0.70
test_hashesFunction · 0.70
test_cloneFunction · 0.70
test_has_contentsFunction · 0.70
test_get_headerFunction · 0.70
test_get_contents_basicFunction · 0.70

Calls 1

finalizeMethod · 0.45

Tested by 15

test_insert_and_getFunction · 0.56
test_removeFunction · 0.56
test_clearFunction · 0.56
test_hashesFunction · 0.56
test_cloneFunction · 0.56
test_has_contentsFunction · 0.56
test_get_headerFunction · 0.56
test_get_contents_basicFunction · 0.56