posix_ttyname_variation7.phpt 688 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. --TEST--
  2. Test function posix_ttyname() by substituting argument 1 with string 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 string values ***\n";
  12. $heredoc = <<<EOT
  13. hello world
  14. EOT;
  15. $variation_array = array(
  16. 'string DQ' => "string",
  17. 'string SQ' => 'string',
  18. 'mixed case string' => "sTrInG",
  19. 'heredoc' => $heredoc,
  20. );
  21. foreach ( $variation_array as $var ) {
  22. var_dump(posix_ttyname( $var ) );
  23. }
  24. ?>
  25. --EXPECT--
  26. *** Test substituting argument 1 with string values ***
  27. bool(false)
  28. bool(false)
  29. bool(false)
  30. bool(false)