xref: /PHP-8.0/ext/date/tests/bug69587.phpt (revision 9ad20837)
1--TEST--
2Bug #69587 (DateInterval properties and isset)
3--FILE--
4<?php
5$datetime1 = new DateTime('2009-10-11');
6$datetime2 = new DateTime('2009-10-13');
7$interval = $datetime1->diff($datetime2);
8
9var_dump(property_exists($interval, 'm'), isset($interval->m), empty($interval->m), empty($interval->d));
10?>
11--EXPECT--
12bool(true)
13bool(true)
14bool(true)
15bool(false)
16