File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed
Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ import (
1616
1717 "github.com/caddyserver/caddy/v2"
1818 "github.com/caddyserver/caddy/v2/caddytest"
19+ "github.com/dunglas/frankenphp"
1920 "github.com/dunglas/frankenphp/internal/fastabs"
2021 "github.com/prometheus/client_golang/prometheus/testutil"
2122 "github.com/stretchr/testify/require"
@@ -1544,6 +1545,9 @@ func TestDd(t *testing.T) {
15441545
15451546// test to force the opcache segfault race condition under concurrency (~1.7s)
15461547func TestOpcacheReset (t * testing.T ) {
1548+ if frankenphp .Version ().VersionID < 80300 {
1549+ t .Skip ("opcache reset test requires PHP 8.3+" )
1550+ }
15471551 tester := caddytest .NewTester (t )
15481552 tester .InitServer (`
15491553 {
Original file line number Diff line number Diff line change @@ -91,6 +91,7 @@ zif_handler orig_opcache_reset;
9191/* Forward declaration */
9292PHP_FUNCTION (frankenphp_opcache_reset );
9393
94+ #if PHP_VERSION_ID >= 80300
9495/* Try to override opcache_reset if opcache is loaded.
9596 * Safe to call multiple times - skips if already overridden in this function
9697 * table. Uses handler comparison instead of orig_opcache_reset check so that
@@ -106,6 +107,7 @@ static void frankenphp_override_opcache_reset(void) {
106107 ZEND_FN (frankenphp_opcache_reset );
107108 }
108109}
110+ #endif
109111
110112void frankenphp_update_local_thread_context (bool is_worker ) {
111113 is_worker_thread = is_worker ;
You can’t perform that action at this time.
0 commit comments