summaryrefslogtreecommitdiff
path: root/ext/opcache/tests
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@zend.com>2014-02-21 11:59:14 +0400
committerDmitry Stogov <dmitry@zend.com>2014-02-21 11:59:14 +0400
commit884bbcd537aad1fcd0265515f69570a20abaf953 (patch)
treeacf73dca0bda66ade73358ed915c9a873acc8c34 /ext/opcache/tests
parente244e2245b9705329d92b92fb0d0d0f50d5af9a4 (diff)
downloadphp-git-884bbcd537aad1fcd0265515f69570a20abaf953.tar.gz
Added function opcache_is_script_cached(). (Danack)
Diffstat (limited to 'ext/opcache/tests')
-rw-r--r--ext/opcache/tests/is_script_cached.phpt15
1 files changed, 15 insertions, 0 deletions
diff --git a/ext/opcache/tests/is_script_cached.phpt b/ext/opcache/tests/is_script_cached.phpt
new file mode 100644
index 0000000000..6f40a7e35d
--- /dev/null
+++ b/ext/opcache/tests/is_script_cached.phpt
@@ -0,0 +1,15 @@
+--TEST--
+Test that script cached info is correct
+--INI--
+opcache.enable=1
+opcache.enable_cli=1
+--SKIPIF--
+<?php require_once('skipif.inc'); ?>
+--FILE--
+<?php
+var_dump(opcache_is_script_cached(__FILE__));
+var_dump(opcache_is_script_cached("nonexistent.php"));
+?>
+--EXPECT--
+bool(true)
+bool(false)