]> granicus.if.org Git - php/commitdiff
MFH: Fixed test for cygwin installs
authorIlia Alshanetsky <iliaa@php.net>
Thu, 20 Oct 2005 14:43:20 +0000 (14:43 +0000)
committerIlia Alshanetsky <iliaa@php.net>
Thu, 20 Oct 2005 14:43:20 +0000 (14:43 +0000)
tests/strings/001.phpt

index 4eacb89592794fe70a3bd2615234ce57aeb22bcf..1d0aeab9353ce164f33648d11a96b26de762478c 100644 (file)
@@ -183,7 +183,10 @@ echo "Testing uniqid: ";
 $str = "prefix";
 $ui1 = uniqid($str);
 $ui2 = uniqid($str);
-if (strlen($ui1) == strlen($ui2) && strlen($ui1) == 19 && $ui1 != $ui2) {
+
+$len = strncasecmp(PHP_OS, 'CYGWIN', 6) ? 19 : 29;
+
+if (strlen($ui1) == strlen($ui2) && strlen($ui1) == $len && $ui1 != $ui2) {
        echo("passed\n");
 } else {
        echo("failed!\n");