Skip to content

Commit 928e4d5

Browse files
Merge pull request phpmyadmin#20193 from MauricioFauth/e2e-test-fix
Fix E2E failing tests
2 parents f0f71c5 + 3598eda commit 928e4d5

2 files changed

Lines changed: 5 additions & 8 deletions

File tree

tests/end-to-end/CreateRemoveUserTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ public function testCreateRemoveUser(): void
7575
$this->byId('text_pma_pw2')->sendKeys($this->txtPassword);
7676

7777
// Make sure the element is visible before clicking
78-
$this->scrollIntoView('createdb-1');
78+
$this->scrollIntoView('createdb-1', 150);
7979
$this->waitForElement('id', 'createdb-1')->click();
8080
$this->waitForElement('id', 'createdb-2')->click();
8181

tests/end-to-end/ServerSettingsTest.php

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,12 @@ protected function setUp(): void
3535
*/
3636
private function saveConfig(): void
3737
{
38-
// Submit the form
39-
$ele = $this->waitForElement(
38+
$this->scrollToBottom();
39+
$this->waitForElement(
4040
'xpath',
4141
"//div[contains(@class, 'tab-pane') and contains(@class, 'show')"
42-
. " and contains(@class, 'active')]//input[@value='Apply']",
43-
);
44-
$this->scrollToBottom();
45-
$this->moveto($ele);
46-
$ele->click();
42+
. " and contains(@class, 'active')]//input[@value='Apply']",
43+
)->click();
4744

4845
$success = $this->waitUntilElementIsPresent('cssSelector', '.alert-success', 5000);
4946
self::assertStringContainsString('Configuration has been saved', $success->getText());

0 commit comments

Comments
 (0)