com php-src: Add test ini_set with invalid time zone : ext/date/tests/ini_set_incorrect.phpt
| From: | Joe Watkins | Date: | Mon, 16 Jan 2017 04:13:01 +0000 |
| Subject: | com php-src: Add test ini_set with invalid time zone : ext/date/tests/ini_set_incorrect.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-96744@lists.php.net to get a copy of this message | ||
Commit: cc9893eb44530bf61d64d53cfb9b5887ffe95490
Author: Niklas Keller <me@kelunik.com> Sun, 15 Jan 2017 23:06:08 +0100
Committer: Joe Watkins <krakjoe@php.net> Mon, 16 Jan 2017 04:13:01 +0000
Parents: 2c7909697a98eb51e3671bc59edc1d7adfa72a0e
Branches: PHP-7.0 PHP-7.1 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=cc9893eb44530bf61d64d53cfb9b5887ffe95490
Log:
Add test ini_set with invalid time zone
Wasn't covered before according to gcov.php.net.
Changed paths:
A ext/date/tests/ini_set_incorrect.phpt
Diff:
diff --git a/ext/date/tests/ini_set_incorrect.phpt b/ext/date/tests/ini_set_incorrect.phpt
new file mode 100644
index 0000000..1077333
--- /dev/null
+++ b/ext/date/tests/ini_set_incorrect.phpt
@@ -0,0 +1,10 @@
+--TEST--
+Test invalid time zone passed to ini_set
+--FILE--
+<?php
+
+ini_set("date.timezone", "Incorrect/Zone");
+
+?>
+--EXPECTF--
+Warning: ini_set(): Invalid date.timezone value 'Incorrect/Zone', we selected the
timezone 'UTC' for now. in %sini_set_incorrect.php on line %d