summaryrefslogtreecommitdiff
path: root/ext/hash/tests
diff options
context:
space:
mode:
authorMichael Wallner <mike@php.net>2005-12-03 10:31:01 +0000
committerMichael Wallner <mike@php.net>2005-12-03 10:31:01 +0000
commit3cfdbdbd12e5e9a4d891d5244155fa333067d2e2 (patch)
tree72743137ead1b05629e423b3afa0ea1d9f4295ad /ext/hash/tests
parentc6fb5f38c0c7f4a70147661cb944ece1c1915344 (diff)
downloadphp-git-3cfdbdbd12e5e9a4d891d5244155fa333067d2e2.tar.gz
- add adler32 test
Diffstat (limited to 'ext/hash/tests')
-rw-r--r--ext/hash/tests/adler32.phpt22
1 files changed, 22 insertions, 0 deletions
diff --git a/ext/hash/tests/adler32.phpt b/ext/hash/tests/adler32.phpt
new file mode 100644
index 0000000000..acfcc2b278
--- /dev/null
+++ b/ext/hash/tests/adler32.phpt
@@ -0,0 +1,22 @@
+--TEST--
+ADLER32
+--SKIPIF--
+<?php extension_loaded('hash') or die('skip'); ?>
+--FILE--
+<?php
+echo hash('adler32', ''), "\n";
+echo hash('adler32', 'a'), "\n";
+echo hash('adler32', 'abc'), "\n";
+echo hash('adler32', 'message digest'), "\n";
+echo hash('adler32', 'abcdefghijklmnopqrstuvwxyz'), "\n";
+echo hash('adler32', 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789'), "\n";
+echo hash('adler32', '12345678901234567890123456789012345678901234567890123456789012345678901234567890'), "\n";
+?>
+--EXPECT--
+01000000
+62006200
+27014d02
+86057529
+200b8690
+0c15db8a
+6910b697