timezone_createEnumeration_basic.phpt 568 B

1234567891011121314151617181920212223242526
  1. --TEST--
  2. IntlTimeZone::createEnumeration(): basic test
  3. --SKIPIF--
  4. <?php
  5. if (!extension_loaded('intl'))
  6. die('skip intl extension not enabled');
  7. --FILE--
  8. <?php
  9. ini_set("intl.error_level", E_WARNING);
  10. $tz = IntlTimeZone::createEnumeration();
  11. var_dump(get_class($tz));
  12. $count = count(iterator_to_array($tz));
  13. var_dump($count > 300);
  14. $tz = intltz_create_enumeration();
  15. var_dump(get_class($tz));
  16. $count2 = count(iterator_to_array($tz));
  17. var_dump($count == $count2);
  18. ?>
  19. ==DONE==
  20. --EXPECT--
  21. string(12) "IntlIterator"
  22. bool(true)
  23. string(12) "IntlIterator"
  24. bool(true)
  25. ==DONE==