Remove typings and replace missing methods with vscodes (#8217)

* remove typings and replace missing methods with vscodes

* fix strict-null-checks

* fix tests
This commit is contained in:
Anthony Dresser
2019-11-05 13:03:20 -08:00
committed by GitHub
parent 4645a8ba6b
commit 22a427f934
184 changed files with 634 additions and 43388 deletions

View File

@@ -10,6 +10,7 @@ import * as assert from 'assert';
import { ConnectionOptionSpecialType, ServiceOptionType } from 'sql/workbench/api/common/sqlExtHostTypes';
import { TestCapabilitiesService } from 'sql/platform/capabilities/test/common/testCapabilitiesService';
import { mssqlProviderName } from 'sql/platform/connection/common/constants';
import { assign } from 'vs/base/common/objects';
suite('SQL ProviderConnectionInfo tests', () => {
let msSQLCapabilities: any;
@@ -202,7 +203,7 @@ suite('SQL ProviderConnectionInfo tests', () => {
test('constructor should initialize the options given a valid model with options', () => {
let options = {};
options['encrypt'] = 'test value';
let conn2 = Object.assign({}, connectionProfile, { options: options });
let conn2 = assign({}, connectionProfile, { options: options });
let conn = new ProviderConnectionInfo(capabilitiesService, conn2);
assert.equal(conn.connectionName, conn2.connectionName);
@@ -223,7 +224,7 @@ suite('SQL ProviderConnectionInfo tests', () => {
test('getOptionsKey should create different id for different server names', () => {
let conn = new ProviderConnectionInfo(capabilitiesService, connectionProfile);
let conn2 = new ProviderConnectionInfo(capabilitiesService, Object.assign({}, connectionProfile, { serverName: connectionProfile.serverName + '1' }));
let conn2 = new ProviderConnectionInfo(capabilitiesService, assign({}, connectionProfile, { serverName: connectionProfile.serverName + '1' }));
assert.notEqual(conn.getOptionsKey(), conn2.getOptionsKey());
});
@@ -260,4 +261,4 @@ suite('SQL ProviderConnectionInfo tests', () => {
assert.equal(expectedProviderId, actual);
});
});
});