1
0
mirror of https://github.com/php/php-src.git synced 2026-04-20 06:21:12 +02:00
Files
archived-php-src/ext/standard/tests/file/bug47517.phpt
Anatol Belski 615c9bfe5a fix condition
2016-12-01 13:33:27 +01:00

22 lines
558 B
PHP

--TEST--
Bug #47517 test registry virtualization disabled
--SKIPIF--
<?php
if (substr(PHP_OS, 0, 3) != 'WIN') {
die('skip only for Windows');
}
exec('net session 2>&1', $out, $status);
if (!$status) {
die('skip test runs under an elevated user account');
}
?>
--FILE--
<?php
/* This has to behave same way on both 64- and 32-bits. */
file_put_contents('C:\Program Files\myfile.txt', 'hello');
?>
==DONE==
--EXPECTF--
Warning: file_put_contents(C:\Program Files\myfile.txt): failed to open stream: Permission denied in %sbug47517.php on line %d
==DONE==