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

Function test_record_item_new

atomic-core/src/record/item.rs:929–941  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

927
928 #[test]
929 fn test_record_item_new() {
930 let path = PathBuf::from("src/main.rs");
931 let inode = Inode::new(42);
932 let parent_pos = Position::ROOT;
933
934 let item = RecordItem::new(path.clone(), inode, parent_pos);
935
936 assert_eq!(item.path(), path.as_path());
937 assert_eq!(item.basename(), "main.rs");
938 assert_eq!(item.inode(), inode);
939 assert_eq!(item.parent_position(), parent_pos);
940 assert!(!item.is_root());
941 }
942
943 #[test]
944 fn test_record_item_root() {

Callers

nothing calls this directly

Calls 1

cloneMethod · 0.45

Tested by

no test coverage detected