summaryrefslogtreecommitdiff
path: root/Zend/tests/magic_methods_019.phpt
diff options
context:
space:
mode:
authorGabriel Caruso <carusogabriel34@gmail.com>2019-05-31 00:45:32 -0300
committerGabriel Caruso <carusogabriel34@gmail.com>2020-08-02 01:29:56 +0200
commite3d06fc79db5af5dba3f4a65bd24b3712711f1ae (patch)
tree7d87cf3b51735e17d9ddf8fede8de93c197ceaf0 /Zend/tests/magic_methods_019.phpt
parent650801ce4520af9d910b1d11a4951aaccf69624a (diff)
downloadphp-git-e3d06fc79db5af5dba3f4a65bd24b3712711f1ae.tar.gz
Ensure correct signatures for magic methods
Diffstat (limited to 'Zend/tests/magic_methods_019.phpt')
-rw-r--r--Zend/tests/magic_methods_019.phpt10
1 files changed, 10 insertions, 0 deletions
diff --git a/Zend/tests/magic_methods_019.phpt b/Zend/tests/magic_methods_019.phpt
new file mode 100644
index 0000000000..85823e6c40
--- /dev/null
+++ b/Zend/tests/magic_methods_019.phpt
@@ -0,0 +1,10 @@
+--TEST--
+__unserialize first parameter must be an array
+--FILE--
+<?php
+class Foo {
+ public function __unserialize(string $name) {}
+}
+?>
+--EXPECTF--
+Fatal error: Foo::__unserialize(): Parameter #1 ($name) must be of type array when declared in %s on line %d