mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-30 09:35:39 -05:00
Wait for SqlToolsService to start before running smoke tests (#15864)
This commit is contained in:
@@ -146,10 +146,18 @@ export class Application {
|
||||
await this.code.waitForWindowIds(ids => ids.length > 0);
|
||||
await this.code.waitForElement('.monaco-workbench');
|
||||
|
||||
// {{SQL CARBON EDIT}} Wait for specified status bar items before considering the app ready - we wait for them together to avoid timing
|
||||
// issues with the status bar items disappearing
|
||||
const statusbarPromises: Promise<string>[] = [];
|
||||
|
||||
if (this.remote) {
|
||||
await this.code.waitForTextContent('.monaco-workbench .statusbar-item[id="status.host"]', ' TestResolver', undefined, 2000);
|
||||
statusbarPromises.push(this.code.waitForTextContent('.monaco-workbench .statusbar-item[id="status.host"]', ' TestResolver', undefined, 2000));
|
||||
}
|
||||
|
||||
// Wait for SQL Tools Service to start before considering the app ready
|
||||
statusbarPromises.push(this.code.waitForTextContent('.monaco-workbench .statusbar-item[id="Microsoft.mssql"]', 'SQL Tools Service Started', undefined, 30000));
|
||||
await Promise.all(statusbarPromises);
|
||||
|
||||
// wait a bit, since focus might be stolen off widgets
|
||||
// as soon as they open (e.g. quick access)
|
||||
await new Promise(c => setTimeout(c, 1000));
|
||||
|
||||
Reference in New Issue
Block a user