mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-23 17:23:02 -05:00
Update Arc extension version and fix Controller connectivity status names (#11498)
* Update connectivity mode names (cherry picked from commit f0aabcfa86d178cdf74470f9fdeded19718bcea2) * Bump package version (cherry picked from commit e08370539006c638d6e25c2f4f23fa2754a3377d)
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
"name": "arc",
|
||||
"displayName": "%arc.displayName%",
|
||||
"description": "%arc.description%",
|
||||
"version": "0.1.0",
|
||||
"version": "0.2.0",
|
||||
"publisher": "Microsoft",
|
||||
"preview": true,
|
||||
"license": "https://raw.githubusercontent.com/Microsoft/azuredatastudio/main/LICENSE.txt",
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
import * as vscode from 'vscode';
|
||||
import * as azurecore from '../../../azurecore/src/azurecore';
|
||||
import * as loc from '../localizedConstants';
|
||||
import { IconPathHelper, IconPath, ResourceType, Connectionmode } from '../constants';
|
||||
import { IconPathHelper, IconPath, ResourceType, ConnectionMode } from '../constants';
|
||||
|
||||
export class UserCancelledError extends Error { }
|
||||
|
||||
@@ -71,10 +71,10 @@ export function getResourceTypeIcon(resourceType: string | undefined): IconPath
|
||||
export function getConnectionModeDisplayText(connectionMode: string | undefined): string {
|
||||
connectionMode = connectionMode ?? '';
|
||||
switch (connectionMode) {
|
||||
case Connectionmode.connected:
|
||||
return loc.connected;
|
||||
case Connectionmode.disconnected:
|
||||
return loc.disconnected;
|
||||
case ConnectionMode.direct:
|
||||
return loc.direct;
|
||||
case ConnectionMode.indirect:
|
||||
return loc.indirect;
|
||||
}
|
||||
return connectionMode;
|
||||
}
|
||||
|
||||
@@ -131,9 +131,9 @@ export const enum Endpoints {
|
||||
controller = 'controller'
|
||||
}
|
||||
|
||||
export const enum Connectionmode {
|
||||
connected = 'connected',
|
||||
disconnected = 'disconnected'
|
||||
export const enum ConnectionMode {
|
||||
direct = 'direct',
|
||||
indirect = 'indirect'
|
||||
}
|
||||
|
||||
export namespace cssStyles {
|
||||
|
||||
@@ -68,8 +68,8 @@ export const running = localize('arc.running', "Running");
|
||||
export const pending = localize('arc.pending', "Pending");
|
||||
export const failed = localize('arc.failed', "Failed");
|
||||
export const unknown = localize('arc.unknown', "Unknown");
|
||||
export const connected = localize('arc.connected', "Connected");
|
||||
export const disconnected = localize('arc.disconnected', "Disconnected");
|
||||
export const direct = localize('arc.direct', "Direct");
|
||||
export const indirect = localize('arc.indirect', "Indirect");
|
||||
export const loading = localize('arc.loading', "Loading...");
|
||||
export const refreshToEnterCredentials = localize('arc.refreshToEnterCredentials', "Refresh node to enter credentials");
|
||||
export const connectToController = localize('arc.connectToController', "Connect to Existing Controller");
|
||||
|
||||
@@ -9,7 +9,7 @@ import 'mocha';
|
||||
import { resourceTypeToDisplayName, parseEndpoint, parseInstanceName, getAzurecoreApi, getResourceTypeIcon, getConnectionModeDisplayText, getDatabaseStateDisplayText, promptForResourceDeletion, promptAndConfirmPassword, getErrorMessage } from '../../common/utils';
|
||||
|
||||
import * as loc from '../../localizedConstants';
|
||||
import { ResourceType, IconPathHelper, Connectionmode as ConnectionMode } from '../../constants';
|
||||
import { ResourceType, IconPathHelper, ConnectionMode as ConnectionMode } from '../../constants';
|
||||
import { MockInputBox } from '../stubs';
|
||||
import { HttpError } from '../../controller/generated/v1/api';
|
||||
import { IncomingMessage } from 'http';
|
||||
@@ -91,8 +91,8 @@ describe('getResourceTypeIcon Method Tests', function () {
|
||||
|
||||
describe('getConnectionModeDisplayText Method Tests', function () {
|
||||
it('Display Name should be correct for valid ResourceType', function (): void {
|
||||
should(getConnectionModeDisplayText(ConnectionMode.connected)).equal(loc.connected);
|
||||
should(getConnectionModeDisplayText(ConnectionMode.disconnected)).equal(loc.disconnected);
|
||||
should(getConnectionModeDisplayText(ConnectionMode.direct)).equal(loc.direct);
|
||||
should(getConnectionModeDisplayText(ConnectionMode.indirect)).equal(loc.indirect);
|
||||
});
|
||||
|
||||
it('Display Name should be correct for unknown value', function (): void {
|
||||
|
||||
Reference in New Issue
Block a user