Seems like there should be an overall bug for this (see T311367, T307504 and T307284), but I ran into it again:
$ php tests/phpunit/phpunit.php '-c' 'tests/phpunit/suite.xml' --stop-on-failure --stop-on-error tests/phpunit/includes/db/LBFactoryTest.php Using PHP 8.1.5 PHPUnit 8.5.27 #StandWithUkraine ....E Time: 512 ms, Memory: 46.50 MB There was 1 error: 1) LBFactoryTest::testChronologyProtector Implicit conversion from float 1657063075.187724 to int loses precision .../core/tests/phpunit/includes/db/LBFactoryTest.php:313 .../includes/libs/rdbms/ChronologyProtector.php:290 .../tests/phpunit/includes/db/LBFactoryTest.php:343 .../tests/phpunit/MediaWikiIntegrationTestCase.php:466 === Logs generated by test case [objectcache] [debug] MainWANObjectCache using store {class} {"class":"EmptyBagOStuff"} === ERRORS! Tests: 5, Assertions: 19, Errors: 1.