Skip to content

Commit

Permalink
do not use real mysql version in tests for running UI tests (#18407)
Browse files Browse the repository at this point in the history
* do not use real mysql version in tests for running UI tests locally

* undo customalerts update

* update screenshot

* updates expected screenshots

Co-authored-by: sgiehl <stefan@matomo.org>
  • Loading branch information
diosmosis and sgiehl committed Dec 1, 2021
1 parent 24bff65 commit caf5b95
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 14 deletions.
5 changes: 5 additions & 0 deletions plugins/CoreHome/Widgets/GetSystemSummary.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

class GetSystemSummary extends Widget
{
const TEST_MYSQL_VERSION = 'mysql-version-redacted';
/**
* @var StoredSegmentService
*/
Expand Down Expand Up @@ -108,6 +109,10 @@ public function render()

private function getMySqlVersion()
{
if (defined('PIWIK_TEST_MODE')) {
return self::TEST_MYSQL_VERSION;
}

$db = Db::get();
return $db->getServerVersion();
}
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions tests/UI/expected-screenshots/Theme_home.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions tests/UI/expected-screenshots/UIIntegrationTest_api_error.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit caf5b95

Please sign in to comment.