diff --git a/ext/tests/post_hook_returns_cloned_modified_object.phpt b/ext/tests/post_hook_returns_cloned_modified_object.phpt index f5985af6..9f20f28e 100644 --- a/ext/tests/post_hook_returns_cloned_modified_object.phpt +++ b/ext/tests/post_hook_returns_cloned_modified_object.phpt @@ -10,7 +10,7 @@ opentelemetry class Foo { public ?string $a = null; - public function __construct(string $a = null) + public function __construct(string|null $a = null) { $this->a = $a; } diff --git a/ext/tests/span_attribute/function_params_non_simple.phpt b/ext/tests/span_attribute/function_params_non_simple.phpt index 1c09ce08..f0a9f80c 100644 --- a/ext/tests/span_attribute/function_params_non_simple.phpt +++ b/ext/tests/span_attribute/function_params_non_simple.phpt @@ -1,7 +1,7 @@ --TEST-- Check if function non-simple types can be passed as function params --SKIPIF-- -= 8.1'); ?> += 80400) die('skip requires PHP >= 8.1 but < 8.4'); ?> --EXTENSIONS-- opentelemetry --INI-- diff --git a/ext/tests/span_attribute/function_params_non_simple_84.phpt b/ext/tests/span_attribute/function_params_non_simple_84.phpt new file mode 100644 index 00000000..3379b11a --- /dev/null +++ b/ext/tests/span_attribute/function_params_non_simple_84.phpt @@ -0,0 +1,61 @@ +--TEST-- +Check if function non-simple types can be passed as function params +--SKIPIF-- += 8.4O'); ?> +--EXTENSIONS-- +opentelemetry +--INI-- +opentelemetry.attr_hooks_enabled = On +--FILE-- + 'bar'], + new \stdClass(), + function(){return 'fn';}, + null, +); +?> +--EXPECTF-- +string(3) "pre" +array(4) { + ["one"]=> + array(1) { + ["foo"]=> + string(3) "bar" + } + ["two"]=> + object(stdClass)#1 (0) { + } + ["three"]=> + object(Closure)#2 (3) { + ["name"]=> + string(%s) "{closure:/%s/tests/span_attribute/function_params_non_simple_84.php:24}" + ["file"]=> + string(%s) "/%s/tests/span_attribute/function_params_non_simple_84.php" + ["line"]=> + int(24) + } + ["four"]=> + NULL +} +string(3) "foo" +string(4) "post" \ No newline at end of file