posix_ttyname_variation3.phpt 816 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. --TEST--
  2. Test function posix_ttyname() by substituting argument 1 with emptyUnsetUndefNull values.
  3. --CREDITS--
  4. Marco Fabbri mrfabbri@gmail.com
  5. Francesco Fullone ff@ideato.it
  6. #PHPTestFest Cesena Italia on 2009-06-20
  7. --EXTENSIONS--
  8. posix
  9. --FILE--
  10. <?php
  11. echo "*** Test substituting argument 1 with emptyUnsetUndefNull values ***\n";
  12. $unset_var = 10;
  13. unset($unset_var);
  14. $variation_array = array(
  15. 'unset var' => @$unset_var,
  16. 'undefined var' => @$undefined_var,
  17. 'empty string DQ' => "",
  18. 'empty string SQ' => '',
  19. 'uppercase NULL' => NULL,
  20. 'lowercase null' => null,
  21. );
  22. foreach ( $variation_array as $var ) {
  23. var_dump(posix_ttyname( $var ) );
  24. }
  25. ?>
  26. --EXPECT--
  27. *** Test substituting argument 1 with emptyUnsetUndefNull values ***
  28. bool(false)
  29. bool(false)
  30. bool(false)
  31. bool(false)
  32. bool(false)
  33. bool(false)