summaryrefslogtreecommitdiff
path: root/Zend/tests/function_arguments/argument_count_incorrect_internal.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'Zend/tests/function_arguments/argument_count_incorrect_internal.phpt')
-rw-r--r--Zend/tests/function_arguments/argument_count_incorrect_internal.phpt13
1 files changed, 7 insertions, 6 deletions
diff --git a/Zend/tests/function_arguments/argument_count_incorrect_internal.phpt b/Zend/tests/function_arguments/argument_count_incorrect_internal.phpt
index a8ba71c0bf..5c0770ff65 100644
--- a/Zend/tests/function_arguments/argument_count_incorrect_internal.phpt
+++ b/Zend/tests/function_arguments/argument_count_incorrect_internal.phpt
@@ -2,9 +2,10 @@
Call internal function with incorrect number of arguments
--FILE--
<?php
-substr("foo");
-array_diff([]);
---EXPECTF--
-Warning: substr() expects at least 2 parameters, 1 given in %s
-
-Warning: array_diff(): at least 2 parameters are required, 1 given in %s
+try {
+ substr("foo");
+} catch (ArgumentCountError $e) {
+ echo $e->getMessage(), "\n";
+}
+--EXPECT--
+substr() expects at least 2 parameters, 1 given