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

Function test_identity_id_base32_roundtrip

atomic-identity/src/identity.rs:586–592  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

584
585 #[test]
586 fn test_identity_id_base32_roundtrip() {
587 let keypair = KeyPair::generate();
588 let id = IdentityId::from_public_key(&keypair.public);
589 let base32 = id.to_base32();
590 let recovered = IdentityId::from_base32(&base32).unwrap();
591 assert_eq!(id, recovered);
592 }
593
594 #[test]
595 fn test_identity_id_short() {

Callers

nothing calls this directly

Calls 2

to_base32Method · 0.45
unwrapMethod · 0.45

Tested by

no test coverage detected