summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Olson <philip@php.net>2011-05-24 23:27:49 +0000
committerPhilip Olson <philip@php.net>2011-05-24 23:27:49 +0000
commit76ec6924cb2274b97d056c2e33898071e798136c (patch)
treec6cf5c6fa43044a0664814360eb8ffa8401a89a1
parent708017dd3f1ac86aeb7555a8ac036b8af202c563 (diff)
downloadphp-git-76ec6924cb2274b97d056c2e33898071e798136c.tar.gz
Updated test. touch() emits E_WARNING for bogus values. Updated 5.3 test to look the same.
-rw-r--r--ext/standard/tests/file/005_variation2.phpt22
1 files changed, 17 insertions, 5 deletions
diff --git a/ext/standard/tests/file/005_variation2.phpt b/ext/standard/tests/file/005_variation2.phpt
index 51919dba60..d14a9bddd7 100644
--- a/ext/standard/tests/file/005_variation2.phpt
+++ b/ext/standard/tests/file/005_variation2.phpt
@@ -49,11 +49,17 @@ function stat_fn( $filename ) {
echo "*** Testing fileattime(), filemtime(), filectime() & touch() : usage variations ***\n";
echo "\n*** testing touch ***\n";
-var_dump(touch(NULL));
-var_dump(touch(false));
-var_dump(touch(''));
-var_dump(touch(' '));
-var_dump(touch('|'));
+$a = touch(NULL);
+$b = touch(false);
+$c = touch('');
+$d = touch(' ');
+$e = touch('|');
+
+var_dump($a);
+var_dump($b);
+var_dump($c);
+var_dump($d);
+var_dump($e);
echo "\n*** testing file info ***";
stat_fn(NULL);
@@ -71,6 +77,12 @@ echo "Done";
*** Testing fileattime(), filemtime(), filectime() & touch() : usage variations ***
*** testing touch ***
+
+Warning: touch(): Unable to create file because No such file or directory in %s on line %d
+
+Warning: touch(): Unable to create file because No such file or directory in %s on line %d
+
+Warning: touch(): Unable to create file because No such file or directory in %s on line %d
bool(false)
bool(false)
bool(false)