Path: blob/main/src/vs/workbench/contrib/chat/test/browser/mockChatWidget.ts
3296 views
/*---------------------------------------------------------------------------------------------1* Copyright (c) Microsoft Corporation. All rights reserved.2* Licensed under the MIT License. See License.txt in the project root for license information.3*--------------------------------------------------------------------------------------------*/45import { Event } from '../../../../../base/common/event.js';6import { URI } from '../../../../../base/common/uri.js';7import { IChatWidget, IChatWidgetService } from '../../browser/chat.js';8import { ChatAgentLocation } from '../../common/constants.js';910export class MockChatWidgetService implements IChatWidgetService {11readonly onDidAddWidget: Event<IChatWidget> = Event.None;1213readonly _serviceBrand: undefined;1415/**16* Returns the most recently focused widget if any.17*/18readonly lastFocusedWidget: IChatWidget | undefined;1920getWidgetByInputUri(uri: URI): IChatWidget | undefined {21return undefined;22}2324getWidgetBySessionId(sessionId: string): IChatWidget | undefined {25return undefined;26}2728getWidgetsByLocations(location: ChatAgentLocation): ReadonlyArray<IChatWidget> {29return [];30}3132getAllWidgets(): ReadonlyArray<IChatWidget> {33throw new Error('Method not implemented.');34}35}363738