fix smoke tests (#124814)

This commit is contained in:
SteVen Batten 2021-05-28 00:30:47 -07:00 committed by GitHub
parent 47d3d743ca
commit e5f70e8e2a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -72,6 +72,11 @@ export class Application {
await this._start();
await this.code.waitForElement('.explorer-folders-view');
if (!this.options.web) {
// Dismiss workspace trust dialog
await this.code.waitAndClick(`.monaco-workbench .dialog-buttons-row a:nth-child(1)`, 10, 10);
}
// https://github.com/microsoft/vscode/issues/118748
// if (expectWalkthroughPart) {
// await this.code.waitForElement(`.editor-instance > div > div.welcomePageFocusElement[tabIndex="0"]`);
@ -82,6 +87,12 @@ export class Application {
await this.stop();
await new Promise(c => setTimeout(c, 1000));
await this._start(options.workspaceOrFolder, options.extraArgs);
await this.code.waitForElement('.explorer-folders-view');
if (!this.options.web) {
// Dismiss workspace trust dialog
await this.code.waitAndClick(`.monaco-workbench .dialog-buttons-row a:nth-child(1)`, 10, 10);
}
}
private async _start(workspaceOrFolder = this.workspacePathOrFolder, extraArgs: string[] = []): Promise<any> {