summaryrefslogtreecommitdiff
path: root/ext/date/tests/date_timestamp_set.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/date/tests/date_timestamp_set.phpt')
-rw-r--r--ext/date/tests/date_timestamp_set.phpt19
1 files changed, 19 insertions, 0 deletions
diff --git a/ext/date/tests/date_timestamp_set.phpt b/ext/date/tests/date_timestamp_set.phpt
new file mode 100644
index 0000000000..e01660193f
--- /dev/null
+++ b/ext/date/tests/date_timestamp_set.phpt
@@ -0,0 +1,19 @@
+--TEST--
+Test the basics to function date_timestamp_set().
+--CREDITS--
+Rodrigo Prado de Jesus <royopa [at] gmail [dot] com>
+--INI--
+date.timezone = UTC;
+date_default_timezone_set("America/Sao_Paulo");
+--FILE--
+<?php
+$dftz021 = date_default_timezone_get(); //UTC
+
+$dtms021 = date_create();
+
+date_timestamp_set($dtms021, 1234567890);
+
+var_dump(date_format($dtms021, 'B => (U) => T Y-M-d H:i:s'));
+?>
+--EXPECTF--
+string(47) "021 => (1234567890) => UTC 2009-Feb-13 23:31:30" \ No newline at end of file