1--TEST-- 2IntlCalendar::get/Least/Greatest/Minimum/Maximum(): bad arguments 3--INI-- 4date.timezone=Atlantic/Azores 5--EXTENSIONS-- 6intl 7--FILE-- 8<?php 9 10$c = new IntlGregorianCalendar(NULL, 'pt_PT'); 11 12try { 13 var_dump($c->getLeastMaximum(-1)); 14} catch (Error $e) { 15 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 16} 17try { 18 var_dump($c->getMaximum(-1)); 19} catch (Error $e) { 20 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 21} 22try { 23 var_dump($c->getGreatestMinimum(-1)); 24} catch (Error $e) { 25 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 26} 27try { 28 var_dump($c->getMinimum(-1)); 29} catch (Error $e) { 30 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 31} 32 33try { 34 var_dump(intlcal_get_least_maximum($c, -1)); 35} catch (Error $e) { 36 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 37} 38try { 39 var_dump(intlcal_get_maximum($c, -1)); 40} catch (Error $e) { 41 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 42} 43try { 44 var_dump(intlcal_get_greatest_minimum($c, -1)); 45} catch (Error $e) { 46 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 47} 48try { 49 var_dump(intlcal_get_minimum($c, -1)); 50} catch (Error $e) { 51 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 52} 53 54try { 55 var_dump(intlcal_get_least_maximum(1, 1)); 56} catch (Error $e) { 57 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 58} 59try { 60 var_dump(intlcal_get_maximum(1, 1)); 61} catch (Error $e) { 62 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 63} 64try { 65 var_dump(intlcal_get_greatest_minimum(1, -1)); 66} catch (Error $e) { 67 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 68} 69try { 70 var_dump(intlcal_get_minimum(1, -1)); 71} catch (Error $e) { 72 echo get_class($e) . ': ' . $e->getCode() . ', ' . $e->getMessage() . \PHP_EOL; 73} 74?> 75--EXPECT-- 76ValueError: 0, IntlCalendar::getLeastMaximum(): Argument #1 ($field) must be a valid field 77ValueError: 0, IntlCalendar::getMaximum(): Argument #1 ($field) must be a valid field 78ValueError: 0, IntlCalendar::getGreatestMinimum(): Argument #1 ($field) must be a valid field 79ValueError: 0, IntlCalendar::getMinimum(): Argument #1 ($field) must be a valid field 80ValueError: 0, intlcal_get_least_maximum(): Argument #2 ($field) must be a valid field 81ValueError: 0, intlcal_get_maximum(): Argument #2 ($field) must be a valid field 82ValueError: 0, intlcal_get_greatest_minimum(): Argument #2 ($field) must be a valid field 83ValueError: 0, intlcal_get_minimum(): Argument #2 ($field) must be a valid field 84TypeError: 0, intlcal_get_least_maximum(): Argument #1 ($calendar) must be of type IntlCalendar, int given 85TypeError: 0, intlcal_get_maximum(): Argument #1 ($calendar) must be of type IntlCalendar, int given 86TypeError: 0, intlcal_get_greatest_minimum(): Argument #1 ($calendar) must be of type IntlCalendar, int given 87TypeError: 0, intlcal_get_minimum(): Argument #1 ($calendar) must be of type IntlCalendar, int given 88