TypePHP 编译器
https://swoole.com/aot/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
33 lines
886 B
33 lines
886 B
--TEST--
|
|
Test fileatime(), filemtime(), filectime() & touch() functions : error conditions
|
|
--FILE--
|
|
<?php
|
|
|
|
echo "*** Testing error conditions ***\n";
|
|
|
|
echo "\n-- Testing with Non-existing files --";
|
|
/* Both invalid arguments */
|
|
var_dump( fileatime("/no/such/file/or/dir") );
|
|
var_dump( filemtime("/no/such/file/or/dir") );
|
|
var_dump( filectime("/no/such/file/or/dir") );
|
|
var_dump( touch("/no/such/file/or/dir", 10) );
|
|
|
|
echo "\nDone";
|
|
?>
|
|
--EXPECTF--
|
|
*** Testing error conditions ***
|
|
|
|
-- Testing with Non-existing files --
|
|
Warning: %s: stat failed for /no/such/file/or/dir in %s on line %d
|
|
bool(false)
|
|
|
|
Warning: %s: stat failed for /no/such/file/or/dir in %s on line %d
|
|
bool(false)
|
|
|
|
Warning: %s: stat failed for /no/such/file/or/dir in %s on line %d
|
|
bool(false)
|
|
|
|
Warning: %s: Unable to create file /no/such/file/or/dir because No such file or directory in %s on line %d
|
|
bool(false)
|
|
|
|
Done
|
|
|