com php-src: forked test for win32: ext/opcache/tests/blacklist-win32.phpt ext/opcache/tests/blacklist.phpt

From: Date: Mon, 13 Jan 2014 16:12:14 +0000
Subject: com php-src: forked test for win32: ext/opcache/tests/blacklist-win32.phpt ext/opcache/tests/blacklist.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-75596@lists.php.net to get a copy of this message
Commit: 8092de3ca304fa3874d1fec866c63838ae1fc38d Author: Anatol Belski <ab@php.net> Mon, 13 Jan 2014 17:12:14 +0100 Parents: ce2f024e9ff4283d22b30d0c20f83c976fb7d3ed Branches: PHP-5.5 PHP-5.6 master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=8092de3ca304fa3874d1fec866c63838ae1fc38d Log: forked test for win32 Changed paths: A ext/opcache/tests/blacklist-win32.phpt M ext/opcache/tests/blacklist.phpt Diff: diff --git a/ext/opcache/tests/blacklist-win32.phpt b/ext/opcache/tests/blacklist-win32.phpt new file mode 100644 index 0000000..909c695 --- /dev/null +++ b/ext/opcache/tests/blacklist-win32.phpt @@ -0,0 +1,34 @@ +--TEST-- +Blacklist (with glob, quote and comments) +--INI-- +opcache.enable=1 +opcache.enable_cli=1 +opcache.blacklist_filename={PWD}/opcache-*.blacklist +opcache.file_update_protection=0 +--SKIPIF-- +<?php require_once('skipif.inc'); ?> +<?php if (substr(PHP_OS, 0, 3) != 'WIN') { die('skip only for Windows'); } ?> +--FILE-- +<?php +$conf = opcache_get_configuration(); +$conf = $conf['blacklist']; +$conf[3] = preg_replace("!^\\Q".dirname(__FILE__)."\\E!", "__DIR__", $conf[3]); +$conf[4] = preg_replace("!^\\Q".dirname(__FILE__)."\\E!", "__DIR__", $conf[4]); +print_r($conf); +include("blacklist.inc"); +$status = opcache_get_status(); +print_r(count($status['scripts'])); +?> +--EXPECTF-- +Array +( + [0] => C:\path\to\foo + [1] => C:\path\to\foo2 + [2] => C:\path\to\bar + [3] => __DIR__\blacklist.inc + [4] => __DIR__\current.php + [5] => %scurrent.php + [6] => %scurrent.php +) +ok +1 diff --git a/ext/opcache/tests/blacklist.phpt b/ext/opcache/tests/blacklist.phpt index 18c205c..0c60425 100644 --- a/ext/opcache/tests/blacklist.phpt +++ b/ext/opcache/tests/blacklist.phpt @@ -7,6 +7,7 @@ opcache.blacklist_filename={PWD}/opcache-*.blacklist opcache.file_update_protection=0 --SKIPIF-- <?php require_once('skipif.inc'); ?> +<?php if (substr(PHP_OS, 0, 3) == 'WIN') { die('skip not for Windows'); } ?> --FILE-- <?php $conf = opcache_get_configuration();

« previous php.cvs (#75596) next »