Fix E2E failing tests

These tests fail sometimes. This is an attempt to fix them.

Signed-off-by: Maurício Meneghini Fauth <mauricio@mfauth.net>
This commit is contained in:
Maurício Meneghini Fauth 2026-02-27 20:00:48 -03:00
parent 1ade4a5c22
commit 3598eda3fd
No known key found for this signature in database
GPG Key ID: 6A16FD38AFC89CC8
2 changed files with 5 additions and 8 deletions

View File

@ -75,7 +75,7 @@ class CreateRemoveUserTest extends TestBase
$this->byId('text_pma_pw2')->sendKeys($this->txtPassword);
// Make sure the element is visible before clicking
$this->scrollIntoView('createdb-1');
$this->scrollIntoView('createdb-1', 150);
$this->waitForElement('id', 'createdb-1')->click();
$this->waitForElement('id', 'createdb-2')->click();

View File

@ -35,15 +35,12 @@ class ServerSettingsTest extends TestBase
*/
private function saveConfig(): void
{
// Submit the form
$ele = $this->waitForElement(
$this->scrollToBottom();
$this->waitForElement(
'xpath',
"//div[contains(@class, 'tab-pane') and contains(@class, 'show')"
. " and contains(@class, 'active')]//input[@value='Apply']",
);
$this->scrollToBottom();
$this->moveto($ele);
$ele->click();
. " and contains(@class, 'active')]//input[@value='Apply']",
)->click();
$success = $this->waitUntilElementIsPresent('cssSelector', '.alert-success', 5000);
self::assertStringContainsString('Configuration has been saved', $success->getText());