1--TEST-- 2IntlTimeZone::getRegion(): errors 3--SKIPIF-- 4<?php 5if (!extension_loaded('intl')) 6 die('skip intl extension not enabled'); 7--FILE-- 8<?php 9ini_set("intl.error_level", E_WARNING); 10 11var_dump(IntlTimeZone::getRegion()); 12var_dump(IntlTimeZone::getRegion(array())); 13var_dump(IntlTimeZone::getRegion('Europe/Lisbon', 4)); 14var_dump(IntlTimeZone::getRegion("foo\x81")); 15var_dump(IntlTimeZone::getRegion("foo")); 16--EXPECTF-- 17Warning: IntlTimeZone::getRegion() expects exactly 1 parameter, 0 given in %s on line %d 18 19Warning: IntlTimeZone::getRegion(): intltz_get_region: bad arguments in %s on line %d 20bool(false) 21 22Warning: IntlTimeZone::getRegion() expects parameter 1 to be string, array given in %s on line %d 23 24Warning: IntlTimeZone::getRegion(): intltz_get_region: bad arguments in %s on line %d 25bool(false) 26 27Warning: IntlTimeZone::getRegion() expects exactly 1 parameter, 2 given in %s on line %d 28 29Warning: IntlTimeZone::getRegion(): intltz_get_region: bad arguments in %s on line %d 30bool(false) 31 32Warning: IntlTimeZone::getRegion(): intltz_get_region: could not convert time zone id to UTF-16 in %s on line %d 33bool(false) 34 35Warning: IntlTimeZone::getRegion(): intltz_get_region: Error obtaining region in %s on line %d 36bool(false) 37