mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-08 23:38:27 +00:00
test: remove redundant list-card action passthrough case
This commit is contained in:
@@ -28,21 +28,6 @@ describe("createListCard", () => {
|
|||||||
const listBox = body.contents[2] as { contents: unknown[] };
|
const listBox = body.contents[2] as { contents: unknown[] };
|
||||||
expect(listBox.contents.length).toBe(8);
|
expect(listBox.contents.length).toBe(8);
|
||||||
});
|
});
|
||||||
|
|
||||||
it("includes actions on items when provided", () => {
|
|
||||||
const items = [
|
|
||||||
{
|
|
||||||
title: "Clickable",
|
|
||||||
action: { type: "message" as const, label: "Click", text: "clicked" },
|
|
||||||
},
|
|
||||||
];
|
|
||||||
const card = createListCard("List", items);
|
|
||||||
const body = card.body as {
|
|
||||||
contents: Array<{ type: string; contents?: Array<{ action?: unknown }> }>;
|
|
||||||
};
|
|
||||||
const listBox = body.contents[2] as { contents: Array<{ action?: unknown }> };
|
|
||||||
expect(listBox.contents[0].action).toEqual(items[0].action);
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
|
|
||||||
describe("createImageCard", () => {
|
describe("createImageCard", () => {
|
||||||
|
|||||||
Reference in New Issue
Block a user