[pkg-php-pear] Bug#861468: php-monolog: FTBFS (failing tests)

Ivo De Decker ivodd at debian.org
Sun Apr 30 14:19:00 UTC 2017

Control: retitle -1 php-monolog: FTBFS (failing tests at the end of the month)


On Sat, Apr 29, 2017 at 12:23:30PM +0000, Santiago Vila wrote:
> There was 1 failure:
> 1) Monolog\Handler\RotatingFileHandlerTest::testRotation with data set "Rotation is not triggered when the file of the current month is already present" (false, 'Y-m', Closure Object (...))
> Failed asserting that true matches expected false.

I guess this is a bug in the test:


$monthCallback = function($ago) {
	return gmmktime(0, 0, 0, date('n') + $ago, date('d'), date('Y'));

This is used with values -1, -2, -3 and -4 for $ago. This will not give the
correct month if the date of the month doesn't exist.

Looking at
it started failing the 29th. With -2 this is February 29th, for which gmmktime
will return March:

$ date;php -r 'print date("c",gmmktime(0, 0, 0, date("n") - 2, date("d"), date("Y")))."\n";'
Sun Apr 30 16:14:25 CEST 2017

The test failure on 2016-08-31 09:49 in the history above is probably the same

We'll see if it builds again tomorrow...



More information about the pkg-php-pear mailing list