xref: /PHP-5.3/ext/date/tests/bug52430.phpt (revision bb8ec8d6)
1--TEST--
2Bug #52430 (date_parse parse 24:xx:xx as valid time)
3--FILE--
4<?php
5var_dump(date_parse('2010-1-1 24:59:59'));
6?>
7--EXPECT--
8array(12) {
9  ["year"]=>
10  int(2010)
11  ["month"]=>
12  int(1)
13  ["day"]=>
14  int(1)
15  ["hour"]=>
16  int(24)
17  ["minute"]=>
18  int(59)
19  ["second"]=>
20  int(59)
21  ["fraction"]=>
22  float(0)
23  ["warning_count"]=>
24  int(1)
25  ["warnings"]=>
26  array(1) {
27    [18]=>
28    string(27) "The parsed time was invalid"
29  }
30  ["error_count"]=>
31  int(0)
32  ["errors"]=>
33  array(0) {
34  }
35  ["is_localtime"]=>
36  bool(false)
37}
38