1--TEST-- 2Maths test for xapic versions of lcg_value() 3--FILE-- 4<?php 5 6echo "MATHS test script started\n"; 7 8 9echo "\n lcg_value tests...\n"; 10for ($i = 0; $i < 100; $i++) { 11 $res = lcg_value(); 12 13 if (!is_float($res) || $res < 0 || $res > 1) { 14 break; 15 } 16} 17 18if ($i != 100) { 19 echo "FAILED\n"; 20} else { 21 echo "PASSED\n"; 22} 23 24echo "MATHS test script completed\n"; 25 26?> 27--EXPECT-- 28MATHS test script started 29 30 lcg_value tests... 31PASSED 32MATHS test script completed 33