1
0
mirror of https://github.com/php/php-src.git synced 2026-04-11 18:13:00 +02:00
Files
archived-php-src/ext/date/tests/bug70153.phpt
m.yakunin d2cde0bfd3 Fix #70153 \DateInterval incorrectly unserialized
Added a separate macro for reading 'days' property, so that bool(false)
is correctly converted to the proper internal representation.
2019-10-18 15:31:14 +02:00

15 lines
302 B
PHP

--TEST--
Bug #70153 (\DateInterval incorrectly unserialized)
--FILE--
<?php
$i1 = \DateInterval::createFromDateString('+1 month');
$i2 = unserialize(serialize($i1));
var_dump($i1->days, $i2->days);
var_dump($i2->special_amount, $i2->special_amount);
?>
--EXPECT--
bool(false)
bool(false)
int(0)
int(0)