xref: /PHP-7.0/Zend/tests/exception_022.phpt (revision 4fb36270)
1--TEST--
2Testing throw exception doesn't crash with wrong params, variant 4
3--FILE--
4<?php
5
6throw new Error(new stdClass);
7
8?>
9--EXPECTF--
10Fatal error: Uncaught Error: Wrong parameters for Error([string $message [, long $code [, Throwable $previous = NULL]]]) in %sexception_022.php:%d
11Stack trace:
12#0 %sexception_022.php(%d): Error->__construct(Object(stdClass))
13#1 {main}
14  thrown in %sexception_022.php on line %d
15