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

Function test_identity_builder

atomic-identity/src/lib.rs:191–201  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

189
190 #[test]
191 fn test_identity_builder() {
192 let identity = Identity::builder("alice")
193 .email("alice@example.com")
194 .usage(IdentityUsage::Personal)
195 .build()
196 .unwrap();
197
198 assert_eq!(identity.name, "alice");
199 assert_eq!(identity.email, Some("alice@example.com".to_string()));
200 assert!(identity.usage.is_personal());
201 }
202
203 #[test]
204 fn test_agent_identity() {

Callers

nothing calls this directly

Calls 4

emailMethod · 0.80
unwrapMethod · 0.45
buildMethod · 0.45
usageMethod · 0.45

Tested by

no test coverage detected