ReflectionFunction_isDisabled_basic.phpt 528 B

123456789101112131415161718192021222324
  1. --TEST--
  2. ReflectionFunction::isDisabled
  3. --CREDITS--
  4. Stefan Koopmanschap <stefan@phpgg.nl>
  5. TestFest PHP|Tek
  6. --INI--
  7. disable_functions=is_file
  8. --FILE--
  9. <?php
  10. try {
  11. $rf = new ReflectionFunction('is_file');
  12. var_dump($rf->isDisabled());
  13. } catch (ReflectionException $e) {
  14. echo $e->getMessage(), "\n";
  15. }
  16. $rf = new ReflectionFunction('is_string');
  17. var_dump($rf->isDisabled());
  18. ?>
  19. --EXPECTF--
  20. Function is_file() does not exist
  21. Deprecated: Method ReflectionFunction::isDisabled() is deprecated in %s on line %d
  22. bool(false)