GeezerVison is showing github.com — test(server): assert a background-wake follow-up delivers its final m… · pingdotgg/t3code@9ca66bb
File treeExpand file treeCollapse file tree Open diff view settings apps/server/src/orchestration-v2
Expand file treeCollapse file tree Open diff view settings Collapse file Copy file name to clipboardExpand all lines: apps/server/src/orchestration-v2/DelegatedCompletionDelivery.test.ts +22Lines changed: 22 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -1487,6 +1487,27 @@ it.layer(Layer.merge(layerTest, ProviderContinuationRequests.layer))( | 1487 | 1487 | yield* eventSink.write({ | 1488 | 1488 | commandId: reconcileCommandId("background-wake-finished"), | 1489 | 1489 | events: [ | | 1490 | + { | | 1491 | + id: EventId.make("event:background-wake-result"), | | 1492 | + type: "message.updated", | | 1493 | + threadId: child.childThreadId, | | 1494 | + runId: run.id, | | 1495 | + occurredAt: now, | | 1496 | + payload: { | | 1497 | + id: MessageId.make("message:background-wake-result"), | | 1498 | + threadId: child.childThreadId, | | 1499 | + runId: run.id, | | 1500 | + nodeId: null, | | 1501 | + role: "assistant", | | 1502 | + text: "The background command finished cleanly.", | | 1503 | + attachments: [], | | 1504 | + streaming: false, | | 1505 | + createdBy: "agent", | | 1506 | + creationSource: "server", | | 1507 | + createdAt: now, | | 1508 | + updatedAt: now, | | 1509 | + }, | | 1510 | + }, | 1490 | 1511 | { | 1491 | 1512 | id: EventId.make("event:background-wake-finished"), | 1492 | 1513 | type: "run.updated", | @@ -1502,6 +1523,7 @@ it.layer(Layer.merge(layerTest, ProviderContinuationRequests.layer))( | 1502 | 1523 | (task) => task.id === run.delegatedTaskId, | 1503 | 1524 | )!; | 1504 | 1525 | assert.equal(followup.status, "completed"); | | 1526 | + assert.equal(followup.result, "The background command finished cleanly."); | 1505 | 1527 | assert.equal(followup.completionDelivery?.state, "claimed"); | 1506 | 1528 | let wake = yield* requests.take; | 1507 | 1529 | while ( | |
|