1--TEST-- 2Test is_readable() function: usage variations - invalid file names 3--SKIPIF-- 4<?php 5require __DIR__ . '/../skipif_root.inc'; 6?> 7--FILE-- 8<?php 9/* test is_executable() with invalid arguments */ 10 11echo "*** Testing is_readable(): usage variations ***\n"; 12 13$file_handle = fopen(__FILE__, "r"); 14unset($file_handle); 15 16echo "\n*** Testing is_readable() on miscellaneous filenames ***\n"; 17$misc_files = array( 18 0, 19 1234, 20 -2.34555, 21 TRUE, 22 FALSE, 23 NULL, 24 " ", 25 @$file_handle 26); 27/* loop through to test each element in the above array 28 is a readable file */ 29foreach( $misc_files as $misc_file ) { 30 var_dump( is_readable($misc_file) ); 31 clearstatcache(); 32} 33 34echo "Done\n"; 35?> 36--EXPECT-- 37*** Testing is_readable(): usage variations *** 38 39*** Testing is_readable() on miscellaneous filenames *** 40bool(false) 41bool(false) 42bool(false) 43bool(false) 44bool(false) 45bool(false) 46bool(false) 47bool(false) 48Done 49