16
17
export class MockPromptsService implements IPromptsService {
19
>
_serviceBrand: undefined;
20
>
21
>
private readonly _onDidChangeCustomAgents = new Emitter<void>();
22
>
readonly onDidChangeCustomAgents = this._onDidChangeCustomAgents.event;
23
>
24
>
private _customModes: ICustomAgent[] = [];
25
>
26
>
setCustomModes(modes: ICustomAgent[]): void {
27
>
this._customModes = modes;
28
>
this._onDidChangeCustomAgents.fire();
29
>
}
30
>
31
>
async getCustomAgents(token: CancellationToken): Promise<readonly ICustomAgent[]> {
32
return this._customModes;
33
}
35
>
// Stub implementations for required interface methods
36
>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
37
>
getSyntaxParserFor(_model: any): any { throw new Error('Not implemented'); }
38
>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
39
>
listPromptFiles(_type: any): Promise<readonly any[]> { throw new Error('Not implemented'); }
40
>
listPromptFilesForStorage(type: PromptsType, storage: PromptsStorage, token: CancellationToken): Promise<readonly IPromptPath[]> { throw new Error('Not implemented'); }
41
>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
42
>
getSourceFolders(_type: any): Promise<readonly any[]> { throw new Error('Not implemented'); }
43
>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
44
>
getResolvedSourceFolders(_type: any): Promise<readonly any[]> { throw new Error('Not implemented'); }
45
>
isValidSlashCommandName(_command: string): boolean { return false; }
46
>
hasPromptSlashCommand(_name: string): boolean { return false; }
47
>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
48
>
resolvePromptSlashCommand(command: string, _sessionType: string | undefined, _token: CancellationToken): Promise<any> { throw new Error('Not implemented'); }
49
>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
50
>
getPromptSlashCommands(_token: CancellationToken): Promise<any[]> { throw new Error('Not implemented'); }
51
>
getPromptSlashCommandName(uri: URI, _token: CancellationToken): Promise<string> { throw new Error('Not implemented'); }
52
>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
53
>
parse(_uri: URI, _type: any, _token: CancellationToken): Promise<any> { throw new Error('Not implemented'); }
54
>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
55
>
parseNew(uri: URI, _token: CancellationToken): Promise<any> { return Promise.resolve({ uri }); }
56
>
getParsedPromptFile(textModel: ITextModel): ParsedPromptFile { throw new Error('Not implemented'); }
57
>
registerContributedFile(type: PromptsType, uri: URI, extension: IExtensionDescription, name: string | undefined, description: string | undefined, when?: string, sessionTypes?: readonly string[]): IDisposable { throw new Error('Not implemented'); }
58
>
getPromptLocationLabel(promptPath: IPromptPath): string { throw new Error('Not implemented'); }
59
>
listNestedAgentMDs(token: CancellationToken): Promise<IAgentInstructionFile[]> { throw new Error('Not implemented'); }
60
>
listAgentInstructions(token: CancellationToken): Promise<IAgentInstructionFile[]> { throw new Error('Not implemented'); }
61
>
getAgentFileURIFromModeFile(oldURI: URI): URI | undefined { throw new Error('Not implemented'); }
62
>
getDisabledPromptFiles(type: PromptsType): ResourceSet { throw new Error('Method not implemented.'); }
63
>
setDisabledPromptFiles(type: PromptsType, uris: ResourceSet): void { throw new Error('Method not implemented.'); }
64
>
registerPromptFileProvider(extension: IExtensionDescription, type: PromptsType, provider: { providePromptFiles: (context: IPromptFileContext, token: CancellationToken) => Promise<IPromptFileResource[] | undefined> }): IDisposable { throw new Error('Method not implemented.'); }
65
>
findAgentSkills(token: CancellationToken): Promise<IAgentSkill[] | undefined> { throw new Error('Method not implemented.'); }
66
>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
67
>
getHooks(_token: CancellationToken): Promise<any> { throw new Error('Method not implemented.'); }
68
>
getInstructionFiles(_token: CancellationToken): Promise<readonly IInstructionFile[]> { throw new Error('Method not implemented.'); }
69
>
getDiscoveryInfo(_type: PromptsType, _token: CancellationToken): Promise<IPromptDiscoveryInfo> { throw new Error('Method not implemented.'); }
70
>
dispose(): void { }
71
>
onDidChangeInstructions: Event<void> = Event.None;
72
>
onDidChangeAgentInstructions: Event<void> = Event.None;
73
>
onDidChangePromptFiles: Event<void> = Event.None;
74
>
onDidChangeSkills: Event<void> = Event.None;
75
>
onDidChangeHooks: Event<void> = Event.None;
76
>
onDidChangeSlashCommands: Event<void> = Event.None;
77
}