Skip to content

Commit

Permalink
Fix search smoke tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyriar committed Oct 2, 2019
1 parent 8f83fba commit e568cf5
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/automation/src/search.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,11 +84,11 @@ export class Search extends Viewlet {
}

async expandReplace(): Promise<void> {
await this.code.waitAndClick(`${VIEWLET} .search-widget .monaco-button.toggle-replace-button.collapse`);
await this.code.waitAndClick(`${VIEWLET} .search-widget .monaco-button.toggle-replace-button.codicon-chevron-right`);
}

async collapseReplace(): Promise<void> {
await this.code.waitAndClick(`${VIEWLET} .search-widget .monaco-button.toggle-replace-button.expand`);
await this.code.waitAndClick(`${VIEWLET} .search-widget .monaco-button.toggle-replace-button.codicon-chevron-down`);
}

async setReplaceText(text: string): Promise<void> {
Expand All @@ -100,12 +100,12 @@ export class Search extends Viewlet {

await retry(
() => this.code.waitAndClick(fileMatch),
() => this.code.waitForElement(`${fileMatch} .action-label.codicon.action-replace-all`, el => !!el && el.top > 0 && el.left > 0, 10)
() => this.code.waitForElement(`${fileMatch} .action-label.codicon.codicon-replace-all`, el => !!el && el.top > 0 && el.left > 0, 10)
);

// ¯\_(ツ)_/¯
await new Promise(c => setTimeout(c, 500));
await this.code.waitAndClick(`${fileMatch} .action-label.codicon.action-replace-all`);
await this.code.waitAndClick(`${fileMatch} .action-label.codicon.codicon-replace-all`);
}

async waitForResultText(text: string): Promise<void> {
Expand Down

0 comments on commit e568cf5

Please sign in to comment.