Skip to content

Commit

Permalink
opcache_is_script_cached: file_cache: test
Browse files Browse the repository at this point in the history
  • Loading branch information
iamacarpet committed Nov 28, 2024
1 parent 200193b commit 15dd23c
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions ext/opcache/tests/gt16979.phpt
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
--TEST--
GH-16979: opcache_is_script_cached support file_cache argument
--INI--
opcache.enable=1
opcache.enable_cli=1
opcache.file_cache={TMP}
opcache.file_cache_only=1
--EXTENSIONS--
opcache
--FILE--
<?php

opcache_compile_file(__FILE__);

var_dump(
opcache_is_script_cached(__FILE__, false)
);

var_dump(
opcache_is_script_cached(__FILE__, true)
);

?>
--EXPECT--
bool(false)
bool(true)

0 comments on commit 15dd23c

Please sign in to comment.