[Test framework] Flaky xx.getFromTo tests
I think I know what the problem is. Will take a closer look tomorrow. Basically a dataprovider can't have dynamic stuff in it that depends on time (or not relevant here but it also can't depend on anything in setUp()), because dataproviders run even before setUpBeforeClass(). Instead in the dataprovider one of the passed values could be a closure and then call the closure from the test, or don't use a dataprovider.
ping @seamuslee @totten
CRM_Report_FormTest::testGetFromTo with data set #2 ('20200514000000', '20200514235959', 'previous.day', '', '')
fail on data set [ previous.day , , ]. Local php time is 2020-05-16 00:19:45 and mysql time is 2020-05-16 00:19:45
Failed asserting that two arrays are equal.
--- Expected
+++ Actual
@@ @@
Array (
- 0 => '20200514000000'
- 1 => '20200514235959'
+ 0 => '20200515000000'
+ 1 => '20200515235959'
/home/jenkins/bknix-dfl/build/core-17335-1ycjc/web/sites/all/modules/civicrm/tests/phpunit/CRM/Report/FormTest.php:74
/home/jenkins/bknix-dfl/build/core-17335-1ycjc/web/sites/all/modules/civicrm/tests/phpunit/CiviTest/CiviUnitTestCase.php:222
/home/jenkins/bknix-dfl/civicrm-buildkit/extern/phpunit6/phpunit6.phar:570