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

Function test_build_agent_author_fallback

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

Source from the content-addressed store, hash-verified

1152
1153 #[test]
1154 fn test_build_agent_author_fallback() {
1155 // Without a real identity store, this falls back to display name.
1156 // In a real install with ~/.atomic/identities/ configured, it would
1157 // produce the +tag format.
1158 let author = build_agent_author(
1159 "claude-code",
1160 "Claude Code",
1161 "60f5cbd2-aa23-40ee-9085-4375dd186ce7",
1162 None,
1163 );
1164
1165 // Can't guarantee identity store exists in test env, so just verify
1166 // the author is valid (either tagged or fallback)
1167 assert!(!author.name.is_empty());
1168 }
1169
1170 /// A name that does not resolve must degrade to a usable author, not an
1171 /// error — recording a turn must never fail over identity selection.

Callers

nothing calls this directly

Calls 1

build_agent_authorFunction · 0.85

Tested by

no test coverage detected