mirror of https://github.com/openclaw/openclaw.git
test(ui): fix agent identity fixture typing
Regeneration-Prompt: | While preparing openclaw/openclaw#35474 against a moving origin/main, pnpm check started failing in ui/src/ui/views/agents-utils.test.ts because AgentIdentityResult now requires agentId and name in addition to avatar. Keep runtime code unchanged and update only the test fixture in the avatar-resolution case so it satisfies the full AgentIdentityResult shape.
This commit is contained in:
parent
cbde94ea9f
commit
145a7b7c4e
|
|
@ -115,9 +115,14 @@ describe("agentLogoUrl", () => {
|
|||
describe("resolveAgentAvatarUrl", () => {
|
||||
it("prefers a runtime avatar URL over non-URL identity avatars", () => {
|
||||
expect(
|
||||
resolveAgentAvatarUrl({ identity: { avatar: "A", avatarUrl: "/avatar/main" } }, {
|
||||
avatar: "A",
|
||||
} as { avatar: string }),
|
||||
resolveAgentAvatarUrl(
|
||||
{ identity: { avatar: "A", avatarUrl: "/avatar/main" } },
|
||||
{
|
||||
agentId: "main",
|
||||
avatar: "A",
|
||||
name: "Main",
|
||||
},
|
||||
),
|
||||
).toBe("/avatar/main");
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue