Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
microsoft
GitHub Repository: microsoft/vscode
Path: blob/main/src/vs/workbench/contrib/mcp/test/common/testMcpService.ts
3296 views
1
/*---------------------------------------------------------------------------------------------
2
* Copyright (c) Microsoft Corporation. All rights reserved.
3
* Licensed under the MIT License. See License.txt in the project root for license information.
4
*--------------------------------------------------------------------------------------------*/
5
6
import { observableValue } from '../../../../../base/common/observable.js';
7
import { IMcpServer, IMcpService, LazyCollectionState } from '../../common/mcpTypes.js';
8
9
export class TestMcpService implements IMcpService {
10
declare readonly _serviceBrand: undefined;
11
public servers = observableValue<readonly IMcpServer[]>(this, []);
12
resetCaches(): void {
13
14
}
15
resetTrust(): void {
16
17
}
18
19
autostart(): Promise<void> {
20
return Promise.resolve();
21
}
22
23
public lazyCollectionState = observableValue(this, { state: LazyCollectionState.AllKnown, collections: [] });
24
25
activateCollections(): Promise<void> {
26
return Promise.resolve();
27
}
28
}
29
30