Skip to content

Commit 2bc1c1d

Browse files
committed
test: fix 8.5 tests
Signed-off-by: Alexandre Rulleau <[email protected]>
1 parent 5f8887b commit 2bc1c1d

File tree

5 files changed

+14
-7
lines changed

5 files changed

+14
-7
lines changed

.gitlab/generate-package.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1259,9 +1259,7 @@
12591259
before_script:
12601260
<?php unset_dd_runner_env_vars() ?>
12611261
- |
1262-
if [[ "$MINOR_MAJOR" == "8.5" ]]; then
1263-
export XDEBUG_SO_NAME=xdebug-3.4.5.so
1264-
elif [[ "$MINOR_MAJOR" == "8.4" ]]; then
1262+
if [[ "$MINOR_MAJOR" == "8.4" ]]; then
12651263
export XDEBUG_SO_NAME=xdebug-3.4.0.so
12661264
elif [[ "$MINOR_MAJOR" == "8.3" ]]; then
12671265
export XDEBUG_SO_NAME=xdebug-3.3.2.so

.gitlab/generate-tracer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -652,7 +652,7 @@ function before_script_steps() {
652652
["8.2", "3.2.2"],
653653
["8.3", "3.3.2"],
654654
["8.4", "3.4.0"],
655-
["8.5", "3.4.5"],
655+
// ["8.5", "3.4.5"], Xdebug not supported yet on 8.5
656656
];
657657
foreach ($xdebug_test_matrix as [$major_minor, $xdebug]):
658658
?>

appsec/tests/extension/module_order_opcache.phpt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ Verify ddappsec is always in the module registry after ddtrace when opcache is p
55
if (!extension_loaded('Zend OPcache')) {
66
die('skip requires opcache');
77
}
8+
if (!version_compare(PHP_VERSION, '8.5.0', '>='))
9+
die('skip: opcache is loaded by default in PHP 8.5+');
810
?>
911
--INI--
1012
extension=ddtrace.so

appsec/tests/integration/src/docker/php/build_dev_php.sh

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,14 @@ function download_php {
3333
return
3434
fi
3535

36-
local download_url="https://downloads.php.net/~edorian/php-8.5.0beta3.tar.gz"
36+
local download_url
37+
if [[ $version_id -lt 50400 ]]; then
38+
download_url="http://museum.php.net/php5/php-${version}.tar.gz"
39+
elif [[ $version_id -ge 80500 ]]; then
40+
download_url="https://downloads.php.net/~edorian/php-8.5.0beta3.tar.gz"
41+
else
42+
download_url="https://www.php.net/distributions/php-${version}.tar.gz"
43+
fi
3744

3845
cd "$download_dir"
3946
curl -L -f -v "$download_url" | tar --strip-components=1 -xzf -

loader/dd_library_loader.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
#include "php_dd_library_loader.h"
1717

1818
#define MIN_API_VERSION 320151012
19-
#define MAX_API_VERSION 420240924
19+
#define MAX_API_VERSION 420240925
2020
#define MAX_INI_API_VERSION MAX_API_VERSION + 1
2121

2222
#define PHP_70_VERSION 20151012
@@ -25,7 +25,7 @@
2525
#define PHP_80_VERSION 20200930
2626

2727
#define MIN_PHP_VERSION "7.0"
28-
#define MAX_PHP_VERSION "8.4"
28+
#define MAX_PHP_VERSION "8.5"
2929

3030
extern zend_module_entry dd_library_loader_mod;
3131

0 commit comments

Comments
 (0)