MCPcopy Create free account
hub / github.com/dfinity/orbit / test_create

Function test_create

core/control-panel/impl/src/services/artifact.rs:101–108  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

99
100 #[test]
101 fn test_create() {
102 let artifact = vec![1, 2, 3];
103 let artifact_id = ARTIFACT_SERVICE.create(artifact.clone()).unwrap();
104 let found_artifact = ARTIFACT_SERVICE.find_by_id(&artifact_id).unwrap();
105
106 assert_eq!(found_artifact.id(), &artifact_id);
107 assert_eq!(found_artifact.artifact(), &artifact);
108 }
109
110 #[test]
111 fn test_create_same_resolves_to_same_id() {

Callers

nothing calls this directly

Calls 2

find_by_idMethod · 0.80
createMethod · 0.45

Tested by

no test coverage detected