diff --git a/.github/workflows/performance-tests.yml b/.github/workflows/performance-tests.yml index 065de46991490..82f338bfad597 100644 --- a/.github/workflows/performance-tests.yml +++ b/.github/workflows/performance-tests.yml @@ -20,10 +20,10 @@ jobs: node-version: "18.x" registry-url: "https://registry.npmjs.org" - - name: Use Python 3.x + - name: Use Python 3.11 uses: actions/setup-python@v4 with: - python-version: "3.x" + python-version: '3.11' - name: Build shell: bash @@ -36,14 +36,12 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # https://github.com/microsoft/vscode-ripgrep/issues/9 - name: Performance (browser) - uses: GabrielBB/xvfb-action@v1 - with: - run: yarn performance:startup:browser + shell: bash + run: yarn performance:startup:browser - name: Performance (Electron) - uses: GabrielBB/xvfb-action@v1 - with: - run: yarn performance:startup:electron + shell: bash + run: xvfb-run yarn performance:startup:electron - name: Analyze performance results uses: benchmark-action/github-action-benchmark@v1 diff --git a/.github/workflows/playwright.yml b/.github/workflows/playwright.yml index 953096017ee3d..03c73cdeb4922 100644 --- a/.github/workflows/playwright.yml +++ b/.github/workflows/playwright.yml @@ -49,6 +49,5 @@ jobs: yarn --cwd examples/playwright build - name: Test (playwright) - uses: GabrielBB/xvfb-action@v1 - with: - run: yarn --cwd examples/playwright ui-tests-ci + shell: bash + run: yarn --cwd examples/playwright ui-tests-ci diff --git a/.github/workflows/production-smoke-test.yml b/.github/workflows/production-smoke-test.yml index 216d39f841422..51a5267eb67c0 100644 --- a/.github/workflows/production-smoke-test.yml +++ b/.github/workflows/production-smoke-test.yml @@ -47,6 +47,5 @@ jobs: yarn --cwd examples/playwright build - name: Run Smoke Test (examples/playwright/src/tests/theia-app) - uses: GabrielBB/xvfb-action@v1 - with: - run: yarn test:playwright theia-app + shell: bash + run: yarn test:playwright theia-app diff --git a/examples/playwright/src/theia-quick-command-palette.ts b/examples/playwright/src/theia-quick-command-palette.ts index 2728bb0b00d21..ca65b86033050 100644 --- a/examples/playwright/src/theia-quick-command-palette.ts +++ b/examples/playwright/src/theia-quick-command-palette.ts @@ -63,13 +63,11 @@ export class TheiaQuickCommandPalette extends TheiaPageObject { if (!await this.isOpen()) { this.open(); } - const input = await this.page.waitForSelector(`${this.selector} .monaco-inputbox .input`); - if (input != null) { - await input.focus(); - await input.type(value, { delay: USER_KEY_TYPING_DELAY }); - if (confirm) { - await this.page.keyboard.press('Enter'); - } + const input = this.page.locator(`${this.selector} .monaco-inputbox .input`); + await input.focus(); + await input.pressSequentially(value, { delay: USER_KEY_TYPING_DELAY }); + if (confirm) { + await this.page.keyboard.press('Enter'); } } diff --git a/examples/playwright/src/theia-rename-dialog.ts b/examples/playwright/src/theia-rename-dialog.ts index 22114444342b5..66281c0cc3d89 100644 --- a/examples/playwright/src/theia-rename-dialog.ts +++ b/examples/playwright/src/theia-rename-dialog.ts @@ -15,15 +15,14 @@ // ***************************************************************************** import { TheiaDialog } from './theia-dialog'; -import { OSUtil, USER_KEY_TYPING_DELAY } from './util'; +import { USER_KEY_TYPING_DELAY } from './util'; export class TheiaRenameDialog extends TheiaDialog { async enterNewName(newName: string): Promise { - const inputField = await this.page.waitForSelector(`${this.blockSelector} .theia-input`); - await inputField.press(OSUtil.isMacOS ? 'Meta+a' : 'Control+a'); - await inputField.type(newName, { delay: USER_KEY_TYPING_DELAY }); - await this.page.waitForTimeout(USER_KEY_TYPING_DELAY); + const inputField = this.page.locator(`${this.blockSelector} .theia-input`); + await inputField.selectText(); + await inputField.pressSequentially(newName, { delay: USER_KEY_TYPING_DELAY }); } async confirm(): Promise { diff --git a/examples/playwright/src/theia-terminal.ts b/examples/playwright/src/theia-terminal.ts index 053cc63a46524..72fd695e06fe9 100644 --- a/examples/playwright/src/theia-terminal.ts +++ b/examples/playwright/src/theia-terminal.ts @@ -38,7 +38,7 @@ export class TheiaTerminal extends TheiaView { async write(text: string): Promise { await this.activate(); const input = await this.waitForInputArea(); - await input.type(text); + await input.fill(text); } async contents(): Promise {