mirror of
https://github.com/Microsoft/vscode
synced 2024-08-25 03:56:03 +00:00
Stub null hover service in some tests
This commit is contained in:
parent
947bb16de1
commit
b127f770c8
|
@ -19,6 +19,8 @@ import { DisposableStore } from 'vs/base/common/lifecycle';
|
|||
import { ensureNoDisposablesAreLeakedInTestSuite } from 'vs/base/test/common/utils';
|
||||
import { CancellationToken } from 'vs/base/common/cancellation';
|
||||
import { URI, UriComponents } from 'vs/base/common/uri';
|
||||
import { IHoverService } from 'vs/platform/hover/browser/hover';
|
||||
import { NullHoverService } from 'vs/platform/hover/test/browser/nullHoverService';
|
||||
|
||||
class TestCommentThread implements CommentThread<IRange> {
|
||||
isDocumentCommentThread(): this is CommentThread<IRange> {
|
||||
|
@ -118,6 +120,7 @@ suite('Comments View', function () {
|
|||
disposables = new DisposableStore();
|
||||
instantiationService = workbenchInstantiationService({}, disposables);
|
||||
instantiationService.stub(IConfigurationService, new TestConfigurationService());
|
||||
instantiationService.stub(IHoverService, NullHoverService);
|
||||
instantiationService.stub(IContextViewService, {});
|
||||
instantiationService.stub(IViewDescriptorService, new TestViewDescriptorService());
|
||||
commentService = instantiationService.createInstance(CommentService);
|
||||
|
|
|
@ -58,6 +58,8 @@ import { IViewsService } from 'vs/workbench/services/views/common/viewsService';
|
|||
import { ChatSlashCommandService, IChatSlashCommandService } from 'vs/workbench/contrib/chat/common/chatSlashCommands';
|
||||
import { ChatWidgetService } from 'vs/workbench/contrib/chat/browser/chatWidget';
|
||||
import { ChatWidgetHistoryService, IChatWidgetHistoryService } from 'vs/workbench/contrib/chat/common/chatWidgetHistoryService';
|
||||
import { IHoverService } from 'vs/platform/hover/browser/hover';
|
||||
import { NullHoverService } from 'vs/platform/hover/test/browser/nullHoverService';
|
||||
|
||||
suite('InteractiveChatController', function () {
|
||||
class TestController extends InlineChatController {
|
||||
|
@ -121,6 +123,7 @@ suite('InteractiveChatController', function () {
|
|||
[IChatVariablesService, new MockChatVariablesService()],
|
||||
[ILogService, new NullLogService()],
|
||||
[ITelemetryService, NullTelemetryService],
|
||||
[IHoverService, NullHoverService],
|
||||
[IExtensionService, new TestExtensionService()],
|
||||
[IContextKeyService, new MockContextKeyService()],
|
||||
[IViewsService, new TestExtensionService()],
|
||||
|
|
Loading…
Reference in a new issue