1--TEST-- 2IntlGregorianCalendar::setDateTime(): error cases 3--EXTENSIONS-- 4intl 5--SKIPIF-- 6<?php if (PHP_INT_SIZE != 8) die("skip: 64-bit only"); ?> 7--FILE-- 8<?php 9try { 10 var_dump(IntlGregorianCalendar::createFromDateTime(99999999999, 1, 1, 1, 1, 1)); 11} catch (ValueError $e) { 12 echo $e->getMessage(), "\n"; 13} 14 15try { 16 var_dump(IntlGregorianCalendar::createFromDateTime(1, 99999999999, 1, 1, 1, 1)); 17} catch (ValueError $e) { 18 echo $e->getMessage(), "\n"; 19} 20 21try { 22 var_dump(IntlGregorianCalendar::createFromDateTime(1, 1, 99999999999, 1, 1, 1)); 23} catch (ValueError $e) { 24 echo $e->getMessage(), "\n"; 25} 26 27try { 28 var_dump(IntlGregorianCalendar::createFromDateTime(1, 1, 1, 99999999999, 1, 1)); 29} catch (ValueError $e) { 30 echo $e->getMessage(), "\n"; 31} 32 33try { 34 var_dump(IntlGregorianCalendar::createFromDateTime(1, 1, 1, 1, 99999999999, 1)); 35} catch (ValueError $e) { 36 echo $e->getMessage(), "\n"; 37} 38 39try { 40 var_dump(IntlGregorianCalendar::createFromDateTime(1, 1, 1, 1, 1, 99999999999)); 41} catch (ValueError $e) { 42 echo $e->getMessage(), "\n"; 43} 44 45?> 46--EXPECT-- 47IntlGregorianCalendar::createFromDateTime(): Argument #1 ($year) must be between -2147483648 and 2147483647 48IntlGregorianCalendar::createFromDateTime(): Argument #2 ($month) must be between -2147483648 and 2147483647 49IntlGregorianCalendar::createFromDateTime(): Argument #3 ($dayOfMonth) must be between -2147483648 and 2147483647 50IntlGregorianCalendar::createFromDateTime(): Argument #4 ($hour) must be between -2147483648 and 2147483647 51IntlGregorianCalendar::createFromDateTime(): Argument #5 ($minute) must be between -2147483648 and 2147483647 52IntlGregorianCalendar::createFromDateTime(): Argument #6 ($second) must be between -2147483648 and 2147483647 53