raising the head after a three-weeks refactoring
[m6w6/ext-psi] / tests / time / asc_gmtime001.phpt
index 3ae78509908b65ca4b84a28b0902ca29393e6227..0108da0e167e8b105b590efd1c9876c075980687 100644 (file)
@@ -11,18 +11,39 @@ psi.directory = {PWD}/../../psi.d:{PWD}
 --FILE--
 ===TEST===
 <?php
-var_dump(psi\asctime(NULL));
-var_dump(psi\asctime_r(NULL));
+try {
+       var_dump(psi\asctime(NULL));
+} catch (Throwable $t) {
+       echo $t->getMessage(),"\n";
+} 
+var_dump(psi\gmtime(1));
 var_dump(psi\asctime(psi\gmtime(1234567890)));
 var_dump(psi\asctime_r(psi\gmtime_r(1234567890)));
 ?>
 ===DONE===
 --EXPECT--
 ===TEST===
-string(25) "Sun Jan  0 00:00:00 1900
-"
-string(25) "Sun Jan  0 00:00:00 1900
-"
+psi\asctime() expects parameter 1 to be array, null given
+array(9) {
+  ["tm_sec"]=>
+  int(1)
+  ["tm_min"]=>
+  int(0)
+  ["tm_hour"]=>
+  int(0)
+  ["tm_mday"]=>
+  int(1)
+  ["tm_mon"]=>
+  int(0)
+  ["tm_year"]=>
+  int(70)
+  ["tm_wday"]=>
+  int(4)
+  ["tm_yday"]=>
+  int(0)
+  ["tm_isdst"]=>
+  int(0)
+}
 string(25) "Fri Feb 13 23:31:30 2009
 "
 string(25) "Fri Feb 13 23:31:30 2009