Make mssql extension a module (#18804)

* Rebase from main branch

* import from module

* Add mssql module ref

Co-authored-by: Charles Gagnon <chgagnon@microsoft.com>
This commit is contained in:
Nemanja Milovančević
2022-03-24 19:09:55 +01:00
committed by GitHub
parent ae8784e462
commit 5e68ff1dfe
71 changed files with 960 additions and 944 deletions

View File

@@ -4,8 +4,8 @@
*--------------------------------------------------------------------------------------------*/
import * as should from 'should';
import * as mssql from '../../../../mssql/src/mssql';
import {SchemaCompareOptionsModel} from '../../models/schemaCompareOptionsModel';
import * as mssql from 'mssql';
import { SchemaCompareOptionsModel } from '../../models/schemaCompareOptionsModel';
describe('Schema Compare Options Model', () => {
it('Should create model and set options successfully', function (): void {
@@ -39,7 +39,7 @@ describe('Schema Compare Options Model', () => {
});
});
const defaultOptions: mssql.DeploymentOptions = {
const defaultOptions: mssql.DeploymentOptions = {
ignoreTableOptions: false,
ignoreSemicolonBetweenStatements: false,
ignoreRouteLifetime: false,

View File

@@ -5,7 +5,7 @@
import * as should from 'should';
import * as vscode from 'vscode';
import * as mssql from '../../../mssql';
import * as mssql from 'mssql';
import * as TypeMoq from 'typemoq';
import * as loc from '../localizedConstants';
import 'mocha';
@@ -67,7 +67,7 @@ describe('SchemaCompareMainWindow.start @DacFx@', function (): void {
let sc = new SchemaCompareTestService();
let result = new SchemaCompareMainWindowTest(sc, mockExtensionContext.object, null);
await result.start({connectionProfile: mockIConnectionProfile});
await result.start({ connectionProfile: mockIConnectionProfile });
should.notEqual(result.sourceEndpointInfo, undefined);
should.equal(result.sourceEndpointInfo.endpointType, mssql.SchemaCompareEndpointType.Database);
@@ -502,7 +502,8 @@ describe('SchemaCompareMainWindow.execute @DacFx@', function (): void {
selectSourceButtonState: true,
selectTargetButtonState: true,
generateScriptButtonState: true,
applyButtonState: true} );
applyButtonState: true
});
});
});

View File

@@ -5,7 +5,7 @@
import * as azdata from 'azdata';
import * as vscode from 'vscode';
import * as mssql from '../../../mssql';
import * as mssql from 'mssql';
import * as should from 'should';
import { SchemaCompareMainWindow } from '../schemaCompareMainWindow';

View File

@@ -4,7 +4,7 @@
*--------------------------------------------------------------------------------------------*/
import * as azdata from 'azdata';
import * as mssql from '../../../mssql';
import * as mssql from 'mssql';
export class SchemaCompareTestService implements mssql.ISchemaCompareService {

View File

@@ -4,7 +4,7 @@
*--------------------------------------------------------------------------------------------*/
import * as azdata from 'azdata';
import * as mssql from '../../../mssql';
import * as mssql from 'mssql';
import should = require('should');
import { AssertionError } from 'assert';

View File

@@ -6,7 +6,7 @@
import * as should from 'should';
import * as azdata from 'azdata';
import * as vscode from 'vscode';
import * as mssql from '../../../mssql';
import * as mssql from 'mssql';
import * as loc from '../localizedConstants';
import * as TypeMoq from 'typemoq';
import * as path from 'path';