Skip to content

Commit

Permalink
test: press enter on searchbox
Browse files Browse the repository at this point in the history
  • Loading branch information
rjaegers committed Nov 2, 2024
1 parent b2ce2fd commit 41fb9f9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/cpp/features/pages/codespace.pom.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { test, expect, type Page, type Locator } from '@playwright/test';
import path from 'path';
import { serialize } from 'v8';

type CommandAndPrompt = {
command: string,
Expand Down Expand Up @@ -101,7 +102,9 @@ export class CodespacePage {
await this.page.keyboard.press('Control+P');
const searchBox = this.page.getByPlaceholder('Search files by name');
await expect(searchBox).toBeVisible();

await searchBox.fill(name);
await searchBox.press('Enter');
await expect(this.page.locator('[id="workbench.parts.editor"]')).toContainText(path.basename(name));
}

Expand Down

0 comments on commit 41fb9f9

Please sign in to comment.