crc32_basic.phpt 546 B

1234567891011121314151617181920212223242526272829
  1. --TEST--
  2. Test crc32() function : basic functionality
  3. --FILE--
  4. <?php
  5. /*
  6. * Testing crc32() : basic functionality
  7. */
  8. echo "*** Testing crc32() : basic functionality ***\n";
  9. // Initialise all required variables
  10. $str = 'string_val1234';
  11. // Calling crc32() with all possible arguments
  12. // checking for the return type of the function
  13. var_dump( is_int(crc32($str)) );
  14. // Printing the returned value from the function
  15. printf("%u\n", crc32($str) );
  16. echo "Done";
  17. ?>
  18. --EXPECT--
  19. *** Testing crc32() : basic functionality ***
  20. bool(true)
  21. 256895812
  22. Done