Skip to content

Commit

Permalink
improve test stability across db engines
Browse files Browse the repository at this point in the history
  • Loading branch information
sgiehl committed Jul 4, 2024
1 parent 8960e89 commit 241a585
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2531,7 +2531,7 @@ private function insertArchiveRow($idSite, $date, $periodLabel, $doneValue = Arc

private function getInvalidatedArchiveTableEntries()
{
return Db::fetchAll("SELECT idarchive, idsite, date1, date2, period, name, report FROM " . Common::prefixTable('archive_invalidations'));
return Db::fetchAll("SELECT idarchive, idsite, date1, date2, period, name, report FROM " . Common::prefixTable('archive_invalidations') . " ORDER BY idinvalidation");
}

private function assertEqualsSorted(array $expectedEntries, array $invalidatedArchiveTableEntries)
Expand All @@ -2554,7 +2554,7 @@ private function getInvalidatedArchiveTableEntriesSummary()
Db::get()->query('SET SESSION group_concat_max_len=' . (128 * 1024));

$table = Common::prefixTable('archive_invalidations');
return Db::fetchAll("SELECT idsite, period, name, report, GROUP_CONCAT(CONCAT(date1, ',', date2) SEPARATOR '|') as dates, COUNT(*) as count FROM $table GROUP BY idsite, period, name, report");
return Db::fetchAll("SELECT idsite, period, name, report, GROUP_CONCAT(CONCAT(date1, ',', date2) SEPARATOR '|') as dates, COUNT(*) as count FROM $table GROUP BY idsite, period, name, report ORDER BY idsite, period, name, report");
}

private static function addVisitToEachSite()
Expand Down

0 comments on commit 241a585

Please sign in to comment.