Skip to content

Commit

Permalink
Fix Export Selenium test
Browse files Browse the repository at this point in the history
Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
  • Loading branch information
MauricioFauth committed Feb 22, 2022
1 parent c8cd855 commit b371b12
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions .github/workflows/test-selenium.yml
Expand Up @@ -93,6 +93,7 @@ jobs:
- name: Set up PHP ${{ env.php-version }}
uses: shivammathur/setup-php@v2
with:
coverage: "none"
php-version: ${{ env.php-version }}
extensions: mbstring, iconv, mysqli, zip, gd, bz2

Expand Down
9 changes: 8 additions & 1 deletion test/selenium/ExportTest.php
Expand Up @@ -4,6 +4,8 @@

namespace PhpMyAdmin\Tests\Selenium;

use Facebook\WebDriver\Exception\ElementClickInterceptedException;

/**
* @coversNothing
*/
Expand Down Expand Up @@ -164,8 +166,13 @@ private function doExport(string $type, string $plugin): string
}

$this->scrollToBottom();
try {
$this->waitForElement('id', 'buttonGo')->click();
} catch (ElementClickInterceptedException $exception) {
$this->scrollToBottom();
$this->waitForElement('id', 'buttonGo')->click();
}

$this->waitForElement('id', 'buttonGo')->click();
$this->waitAjax();

return $this->waitForElement('id', 'textSQLDUMP')->getText();
Expand Down

0 comments on commit b371b12

Please sign in to comment.