Add type for RooCodeEventName.TaskSpawned (#7465)

This commit is contained in:
Matt Rubens 2025-08-27 17:40:06 -04:00 committed by Hannes Rudolph
parent 11dd48a685
commit 602a4fea7f
2 changed files with 5 additions and 3 deletions

View file

@ -68,7 +68,6 @@ export type TaskProviderEvents = {
[RooCodeEventName.TaskInteractive]: [taskId: string]
[RooCodeEventName.TaskResumable]: [taskId: string]
[RooCodeEventName.TaskIdle]: [taskId: string]
[RooCodeEventName.TaskPaused]: [taskId: string]
[RooCodeEventName.TaskUnpaused]: [taskId: string]
[RooCodeEventName.TaskSpawned]: [taskId: string]
@ -82,8 +81,8 @@ export type TaskProviderEvents = {
}
/**
* TaskLike
*/
* TaskLike
*/
export interface CreateTaskOptions {
enableDiff?: boolean

View file

@ -158,6 +158,9 @@ describe("newTaskTool", () => {
)
// Verify side effects
expect(mockEmit).toHaveBeenCalledWith("taskSpawned", "mock-subtask-id")
expect(mockCline.isPaused).toBe(true)
expect(mockEmit).toHaveBeenCalledWith("taskPaused", "mock-parent-task-id")
expect(mockPushToolResult).toHaveBeenCalledWith(expect.stringContaining("Successfully created new task"))
})