mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-09 17:52:34 -05:00
show proper message when extension is not installed for a connection provider (#19377)
* show extension not installed error * extension provider mapping * fix tests
This commit is contained in:
@@ -123,7 +123,7 @@ suite('ConnectionDialogService tests', () => {
|
||||
}
|
||||
};
|
||||
});
|
||||
testConnectionDialog = new TestConnectionDialogWidget(providerDisplayNames, providerNameToDisplayMap['MSSQL'], providerNameToDisplayMap, testInstantiationService, mockConnectionManagementService.object, undefined, undefined, viewDescriptorService, new TestThemeService(), new TestLayoutService(), new NullAdsTelemetryService(), new MockContextKeyService(), undefined, new NullLogService(), new TestTextResourcePropertiesService(new TestConfigurationService), new TestConfigurationService(), new TestCapabilitiesService());
|
||||
testConnectionDialog = new TestConnectionDialogWidget(providerDisplayNames, providerNameToDisplayMap['MSSQL'], providerNameToDisplayMap, testInstantiationService, mockConnectionManagementService.object, undefined, undefined, viewDescriptorService, new TestThemeService(), new TestLayoutService(), new NullAdsTelemetryService(), new MockContextKeyService(), undefined, new NullLogService(), new TestTextResourcePropertiesService(new TestConfigurationService), new TestConfigurationService(), new TestCapabilitiesService(), undefined, undefined, undefined);
|
||||
testConnectionDialog.render();
|
||||
testConnectionDialog['renderBody'](DOM.createStyleSheet());
|
||||
(connectionDialogService as any)._connectionDialog = testConnectionDialog;
|
||||
|
||||
@@ -65,7 +65,7 @@ suite('ConnectionDialogWidget tests', () => {
|
||||
new TestCapabilitiesService());
|
||||
let providerDisplayNames = ['Mock SQL Server'];
|
||||
let providerNameToDisplayMap = { 'MSSQL': 'Mock SQL Server' };
|
||||
connectionDialogWidget = new TestConnectionDialogWidget(providerDisplayNames, providerNameToDisplayMap['MSSQL'], providerNameToDisplayMap, cmInstantiationService, mockConnectionManagementService.object, undefined, undefined, viewDescriptorService, new TestThemeService(), new TestLayoutService(), new NullAdsTelemetryService(), new MockContextKeyService(), undefined, new NullLogService(), new TestTextResourcePropertiesService(new TestConfigurationService()), new TestConfigurationService(), new TestCapabilitiesService());
|
||||
connectionDialogWidget = new TestConnectionDialogWidget(providerDisplayNames, providerNameToDisplayMap['MSSQL'], providerNameToDisplayMap, cmInstantiationService, mockConnectionManagementService.object, undefined, undefined, viewDescriptorService, new TestThemeService(), new TestLayoutService(), new NullAdsTelemetryService(), new MockContextKeyService(), undefined, new NullLogService(), new TestTextResourcePropertiesService(new TestConfigurationService()), new TestConfigurationService(), new TestCapabilitiesService(), undefined, undefined, undefined);
|
||||
element = DOM.createStyleSheet();
|
||||
connectionDialogWidget.render();
|
||||
connectionDialogWidget['renderBody'](element);
|
||||
|
||||
@@ -17,6 +17,9 @@ import { ITextResourcePropertiesService } from 'vs/editor/common/services/textRe
|
||||
import { IViewDescriptorService } from 'vs/workbench/common/views';
|
||||
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
|
||||
import { ICapabilitiesService } from 'sql/platform/capabilities/common/capabilitiesService';
|
||||
import { INotificationService } from 'vs/platform/notification/common/notification';
|
||||
import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet';
|
||||
import { ICommandService } from 'vs/platform/commands/common/commands';
|
||||
|
||||
export class TestConnectionDialogWidget extends ConnectionDialogWidget {
|
||||
constructor(
|
||||
@@ -36,8 +39,11 @@ export class TestConnectionDialogWidget extends ConnectionDialogWidget {
|
||||
@ILogService logService: ILogService,
|
||||
@ITextResourcePropertiesService textResourcePropertiesService: ITextResourcePropertiesService,
|
||||
@IConfigurationService configurationService: IConfigurationService,
|
||||
@ICapabilitiesService capabilitiesService: ICapabilitiesService
|
||||
@ICapabilitiesService capabilitiesService: ICapabilitiesService,
|
||||
@INotificationService notificationService: INotificationService,
|
||||
@IViewletService viewletService: IViewletService,
|
||||
@ICommandService commandService: ICommandService
|
||||
) {
|
||||
super(providerDisplayNameOptions, selectedProviderType, providerNameToDisplayNameMap, _instantiationService, _connectionManagementService, _contextMenuService, _contextViewService, themeService, layoutService, telemetryService, contextKeyService, clipboardService, logService, textResourcePropertiesService, configurationService, capabilitiesService);
|
||||
super(providerDisplayNameOptions, selectedProviderType, providerNameToDisplayNameMap, _instantiationService, _connectionManagementService, _contextMenuService, _contextViewService, themeService, layoutService, telemetryService, contextKeyService, clipboardService, logService, textResourcePropertiesService, configurationService, capabilitiesService, notificationService, viewletService, commandService);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user