--TEST-- Test fileperms() & chmod() functions: usage variation - misc. perms --SKIPIF-- --FILE-- getMessage(), "\n"; } try { var_dump( chmod($dir_name, $permission) ); printf("%o", fileperms($dir_name) ); echo "\n"; clearstatcache(); } catch (TypeError $e) { echo $e->getMessage(), "\n"; } $count++; } echo "*** Done ***\n"; ?> --CLEAN-- --EXPECTF-- *** Testing fileperms() & chmod() : usage variations *** *** Testing fileperms(), chmod() with miscellaneous permissions *** -- Iteration 1 -- bool(true) 107777 bool(true) 47777 -- Iteration 2 -- bool(true) 100000 bool(true) 40000 -- Iteration 3 -- bool(true) 101000 bool(true) 41000 -- Iteration 4 -- bool(true) 101111 bool(true) 41111 -- Iteration 5 -- bool(true) 107001 bool(true) 47001 -- Iteration 6 -- bool(true) 100001 bool(true) 40001 -- Iteration 7 -- bool(true) 101411 bool(true) 41411 -- Iteration 8 -- bool(true) 107141 bool(true) 47141 -- Iteration 9 -- bool(true) 100637 bool(true) 40637 -- Iteration 10 -- bool(true) 103567 bool(true) 43567 -- Iteration 11 -- bool(true) 103567 bool(true) 43567 -- Iteration 12 -- chmod() expects parameter 2 to be int, string given chmod() expects parameter 2 to be int, string given -- Iteration 13 -- chmod() expects parameter 2 to be int, string given chmod() expects parameter 2 to be int, string given -- Iteration 14 -- chmod() expects parameter 2 to be int, string given chmod() expects parameter 2 to be int, string given -- Iteration 15 -- chmod() expects parameter 2 to be int, string given chmod() expects parameter 2 to be int, string given *** Done ***