1--TEST--
2IntlTimeZone::getDisplayName(): type parameter (ICU >= 49 && ICU < 50.1.2)
3--SKIPIF--
4<?php if (!extension_loaded('intl')) die('skip intl extension not enabled'); ?>
5<?php if (version_compare(INTL_ICU_VERSION, '50.1.2') >=  0) die('skip for ICU < 50.1.2'); ?>
6--FILE--
7<?php
8ini_set("intl.error_level", E_WARNING);
9ini_set("error_reporting", -1);
10ini_set("display_errors", 1);
11
12$lsb = IntlTimeZone::createTimeZone('Europe/Lisbon');
13
14ini_set('intl.default_locale', 'en_US');
15var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_SHORT));
16var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_LONG));
17var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_SHORT_GENERIC));
18var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_LONG_GENERIC));
19var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_SHORT_GMT));
20var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_LONG_GMT));
21var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_SHORT_COMMONLY_USED));
22var_dump($lsb->getDisplayName(false, IntlTimeZone::DISPLAY_GENERIC_LOCATION));
23
24?>
25--EXPECT--
26string(3) "GMT"
27string(30) "Western European Standard Time"
28string(22) "Portugal Time (Lisbon)"
29string(21) "Western European Time"
30string(5) "+0000"
31string(3) "GMT"
32string(3) "GMT"
33string(22) "Portugal Time (Lisbon)"
34