validate: include decls in the multiple validation rounds
[m6w6/ext-psi] / tests / time / asc_gmtime001.phpt
1 --TEST--
2 asctime/gmtime
3 --SKIPIF--
4 <?php
5 extension_loaded("psi") or die("skip - need ext/psi");
6 ?>
7 --ENV--
8 TZ=UTC
9 --INI--
10 psi.directory = {PWD}/../../psi.d:{PWD}
11 --FILE--
12 ===TEST===
13 <?php
14 try {
15 var_dump(psi\asctime(NULL));
16 } catch (Throwable $t) {
17 echo $t->getMessage(),"\n";
18 }
19 var_dump(psi\gmtime(1));
20 var_dump(psi\asctime(psi\gmtime(1234567890)));
21 var_dump(psi\asctime_r(psi\gmtime_r(1234567890)));
22 ?>
23 ===DONE===
24 --EXPECT--
25 ===TEST===
26 psi\asctime() expects parameter 1 to be array, null given
27 array(9) {
28 ["tm_sec"]=>
29 int(1)
30 ["tm_min"]=>
31 int(0)
32 ["tm_hour"]=>
33 int(0)
34 ["tm_mday"]=>
35 int(1)
36 ["tm_mon"]=>
37 int(0)
38 ["tm_year"]=>
39 int(70)
40 ["tm_wday"]=>
41 int(4)
42 ["tm_yday"]=>
43 int(0)
44 ["tm_isdst"]=>
45 int(0)
46 }
47 string(25) "Fri Feb 13 23:31:30 2009
48 "
49 string(25) "Fri Feb 13 23:31:30 2009
50 "
51 ===DONE===