readgzfile_variation12.phpt 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. --TEST--
  2. Test function readgzfile() by substituting argument 2 with int values.
  3. --SKIPIF--
  4. <?php
  5. if (!extension_loaded('zlib')) die ('skip zlib extension not available in this build');
  6. ?>
  7. --FILE--
  8. <?php
  9. $filename = dirname(__FILE__)."/004.txt.gz";
  10. $variation = array (
  11. 'int 0' => 0,
  12. 'int 1' => 1,
  13. 'int 12345' => 12345,
  14. 'int -12345' => -2345,
  15. );
  16. foreach ( $variation as $var ) {
  17. var_dump(readgzfile( $filename, $var ) );
  18. }
  19. ?>
  20. ===DONE===
  21. --EXPECT--
  22. When you're taught through feelings
  23. Destiny flying high above
  24. all I know is that you can realize it
  25. Destiny who cares
  26. as it turns around
  27. and I know that it descends down on me
  28. int(176)
  29. When you're taught through feelings
  30. Destiny flying high above
  31. all I know is that you can realize it
  32. Destiny who cares
  33. as it turns around
  34. and I know that it descends down on me
  35. int(176)
  36. When you're taught through feelings
  37. Destiny flying high above
  38. all I know is that you can realize it
  39. Destiny who cares
  40. as it turns around
  41. and I know that it descends down on me
  42. int(176)
  43. When you're taught through feelings
  44. Destiny flying high above
  45. all I know is that you can realize it
  46. Destiny who cares
  47. as it turns around
  48. and I know that it descends down on me
  49. int(176)
  50. ===DONE===