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

Function test_resolve_no_identity_dir

atomic-agent/src/identity.rs:579–595  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

577
578 #[test]
579 fn test_resolve_no_identity_dir() {
580 let dir = TempDir::new().unwrap();
581 let nonexistent = dir.path().join("does-not-exist");
582
583 let options = AgentAuthorOptions {
584 agent_name: "claude-code",
585 agent_display_name: "Claude Code",
586 session_id: "60f5cbd2",
587 identity_dir: Some(nonexistent),
588 };
589
590 let author = resolve_agent_author(&options);
591
592 // Should fall back to display name
593 assert_eq!(author.name, "Claude Code");
594 assert!(author.email.is_none());
595 }
596
597 #[test]
598 fn test_resolve_empty_identity_dir() {

Callers

nothing calls this directly

Calls 3

resolve_agent_authorFunction · 0.85
unwrapMethod · 0.45
pathMethod · 0.45

Tested by

no test coverage detected