Lint fixes

This commit is contained in:
Matt Rubens 2025-09-26 00:56:15 -04:00
parent 74991bdefe
commit ff7c9b7628
4 changed files with 6 additions and 6 deletions

View file

@ -11,7 +11,7 @@ suite("Roo Code Modes", function () {
test("Should handle switching modes correctly", async () => {
const modes: string[] = []
globalThis.api.on(RooCodeEventName.TaskModeSwitched, (_taskId, mode) => modes.push(mode))
globalThis.api.on(RooCodeEventName.TaskModeSwitched, (_taskId: string, mode: string) => modes.push(mode))
const switchModesTaskId = await globalThis.api.startNewTask({
configuration: { mode: "code", alwaysAllowModeSwitch: true, autoApprovalEnabled: true },

View file

@ -10,7 +10,7 @@ suite.skip("Roo Code Subtasks", () => {
const messages: Record<string, ClineMessage[]> = {}
api.on(RooCodeEventName.Message, ({ taskId, message }) => {
api.on(RooCodeEventName.Message, ({ taskId, message }: { taskId: string; message: ClineMessage }) => {
if (message.type === "say" && message.partial === false) {
messages[taskId] = messages[taskId] || []
messages[taskId].push(message)
@ -37,7 +37,7 @@ suite.skip("Roo Code Subtasks", () => {
let spawnedTaskId: string | undefined = undefined
// Wait for the subtask to be spawned and then cancel it.
api.on(RooCodeEventName.TaskSpawned, (_, childTaskId) => (spawnedTaskId = childTaskId))
api.on(RooCodeEventName.TaskSpawned, (_: string, childTaskId: string) => (spawnedTaskId = childTaskId))
await waitFor(() => !!spawnedTaskId)
await sleep(1_000) // Give the task a chance to start and populate the history.
await api.cancelCurrentTask()

View file

@ -13,7 +13,7 @@ suite("Roo Code Task", function () {
const messages: ClineMessage[] = []
api.on(RooCodeEventName.Message, ({ message }) => {
api.on(RooCodeEventName.Message, ({ message }: { message: ClineMessage }) => {
if (message.type === "say" && message.partial === false) {
messages.push(message)
}

View file

@ -46,7 +46,7 @@ type WaitUntilAbortedOptions = WaitForOptions & {
export const waitUntilAborted = async ({ api, taskId, ...options }: WaitUntilAbortedOptions) => {
const set = new Set<string>()
api.on(RooCodeEventName.TaskAborted, (taskId) => set.add(taskId))
api.on(RooCodeEventName.TaskAborted, (abortedTaskId: string) => set.add(abortedTaskId))
await waitFor(() => set.has(taskId), options)
}
@ -57,7 +57,7 @@ type WaitUntilCompletedOptions = WaitForOptions & {
export const waitUntilCompleted = async ({ api, taskId, ...options }: WaitUntilCompletedOptions) => {
const set = new Set<string>()
api.on(RooCodeEventName.TaskCompleted, (taskId) => set.add(taskId))
api.on(RooCodeEventName.TaskCompleted, (completedTaskId: string) => set.add(completedTaskId))
await waitFor(() => set.has(taskId), options)
}