feat: strengthen task workflow and compaction recovery
This commit is contained in:
@@ -170,6 +170,17 @@ test("tool errors show one summary line until expanded", () => {
|
||||
assert.deepEqual(expanded, ["✗ Update failed · 2 validation errors", " - first", " - second"]);
|
||||
});
|
||||
|
||||
test("expanded task details tolerate an omitted description", () => {
|
||||
const state = new TaskState();
|
||||
state.add([{ name: "Name only" }]);
|
||||
const result = {
|
||||
content: [{ type: "text", text: "details" }],
|
||||
details: { action: "get" as const, snapshot: state.snapshot(), affected: state.list() },
|
||||
};
|
||||
const lines = renderToolResult(result, true, plainTheme as never).render(80).map(stripAnsi);
|
||||
assert.deepEqual(lines, ["✓ 1 task", " ○ 1. Name only", " Parent root · Children none"]);
|
||||
});
|
||||
|
||||
test("snapshot stats count every task node", () => {
|
||||
assert.deepEqual(snapshotStats(fixture().list()), {
|
||||
total: 5,
|
||||
|
||||
Reference in New Issue
Block a user