summaryrefslogtreecommitdiff
path: root/ext/standard/tests/file/lchown_error.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/standard/tests/file/lchown_error.phpt')
-rw-r--r--ext/standard/tests/file/lchown_error.phpt10
1 files changed, 1 insertions, 9 deletions
diff --git a/ext/standard/tests/file/lchown_error.phpt b/ext/standard/tests/file/lchown_error.phpt
index fd54b482b3..dbd9a7bbe8 100644
--- a/ext/standard/tests/file/lchown_error.phpt
+++ b/ext/standard/tests/file/lchown_error.phpt
@@ -4,15 +4,7 @@ Test lchown() function : error functionality
<?php
if (substr(PHP_OS, 0, 3) == 'WIN') die('skip no windows support');
if (!function_exists("posix_getuid")) die("skip no posix_getuid()");
-// Skip if being run by root
-$filename = __DIR__."/lchow_error_root_check.tmp";
-$fp = fopen($filename, 'w');
-fclose($fp);
-if(fileowner($filename) == 0) {
- unlink ($filename);
- die('skip cannot be run as root');
-}
-unlink($filename);
+require __DIR__ . '/../skipif_root.inc';
?>
--FILE--
<?php