diff options
Diffstat (limited to 'ext/date/tests/date_timestamp_set_wrongparam_003.phpt')
-rw-r--r-- | ext/date/tests/date_timestamp_set_wrongparam_003.phpt | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/ext/date/tests/date_timestamp_set_wrongparam_003.phpt b/ext/date/tests/date_timestamp_set_wrongparam_003.phpt new file mode 100644 index 0000000000..f965334d9d --- /dev/null +++ b/ext/date/tests/date_timestamp_set_wrongparam_003.phpt @@ -0,0 +1,19 @@ +--TEST-- +Check the function date_timestamp_set() with second parameter wrong (array). +--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 = new DateTime(); + +$wrong_parameter = array(); + +date_timestamp_set($dtms021, $wrong_parameter); +?> +--EXPECTF-- +Warning: date_timestamp_set() expects parameter 2 to be long, array given in %s on line %d
\ No newline at end of file |