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