ReflectionClass_getInterfaces_004.phpt 801 B

123456789101112131415161718192021222324252627
  1. --TEST--
  2. ReflectionClass::getInterfaces() - wrong param count
  3. --CREDITS--
  4. Robin Fernandes <robinf@php.net>
  5. Steve Seear <stevseea@php.net>
  6. --FILE--
  7. <?php
  8. interface I {}
  9. class C implements I {}
  10. $rc = new ReflectionClass('C');
  11. var_dump($rc->getInterfaces(null));
  12. var_dump($rc->getInterfaces('X'));
  13. var_dump($rc->getInterfaces(true));
  14. var_dump($rc->getInterfaces(array(1,2,3)));
  15. ?>
  16. --EXPECTF--
  17. Warning: ReflectionClass::getInterfaces() expects exactly 0 parameters, 1 given in %s on line %d
  18. NULL
  19. Warning: ReflectionClass::getInterfaces() expects exactly 0 parameters, 1 given in %s on line %d
  20. NULL
  21. Warning: ReflectionClass::getInterfaces() expects exactly 0 parameters, 1 given in %s on line %d
  22. NULL
  23. Warning: ReflectionClass::getInterfaces() expects exactly 0 parameters, 1 given in %s on line %d
  24. NULL