mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 10:58:30 -05:00
Fixed Schema compare integration tests by adding retry (#13649)
This commit is contained in:
@@ -17,19 +17,21 @@ import { promisify } from 'util';
|
||||
|
||||
const retryCount = 24; // 2 minutes
|
||||
const dacpac1: string = path.join(__dirname, '../../testData/Database1.dacpac');
|
||||
suite('Dacpac integration test suite', () => {
|
||||
|
||||
|
||||
suite('Dacpac integration test suite @DacFx@', () => {
|
||||
suiteSetup(async function () {
|
||||
await utils.sleep(5000); // To ensure the providers are registered.
|
||||
console.log(`Start dacpac tests`);
|
||||
});
|
||||
|
||||
test('Deploy and extract dacpac @UNSTABLE@', async function () {
|
||||
this.timeout(5 * 60 * 1000);
|
||||
const server = await getStandaloneServer();
|
||||
await utils.connectToServer(server);
|
||||
const connectionId = await utils.connectToServer(server);
|
||||
assert(connectionId, `Failed to connect to "${server.serverName}"`);
|
||||
|
||||
const nodes = <azdata.objectexplorer.ObjectExplorerNode[]>await azdata.objectexplorer.getActiveConnectionNodes();
|
||||
const index = nodes.findIndex(node => node.nodePath.includes(server.serverName));
|
||||
const ownerUri = await azdata.connection.getUriForConnection(nodes[index].connectionId);
|
||||
const ownerUri = await azdata.connection.getUriForConnection(connectionId);
|
||||
const now = new Date();
|
||||
const databaseName = 'ADS_deployDacpac_' + now.getTime().toString();
|
||||
|
||||
@@ -70,12 +72,13 @@ suite('Dacpac integration test suite', () => {
|
||||
|
||||
const bacpac1: string = path.join(__dirname, '..', '..', 'testData', 'Database1.bacpac');
|
||||
test('Import and export bacpac @UNSTABLE@', async function () {
|
||||
this.timeout(5 * 60 * 1000);
|
||||
const server = await getStandaloneServer();
|
||||
await utils.connectToServer(server);
|
||||
|
||||
const nodes = <azdata.objectexplorer.ObjectExplorerNode[]>await azdata.objectexplorer.getActiveConnectionNodes();
|
||||
const index = nodes.findIndex(node => node.nodePath.includes(server.serverName));
|
||||
const ownerUri = await azdata.connection.getUriForConnection(nodes[index].connectionId);
|
||||
const connectionId = await utils.connectToServer(server);
|
||||
assert(connectionId, `Failed to connect to "${server.serverName}"`);
|
||||
const ownerUri = await azdata.connection.getUriForConnection(connectionId);
|
||||
const now = new Date();
|
||||
const databaseName = 'ADS_importBacpac_' + now.getTime().toString();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user