xref: /PHP-8.0/ext/pdo/tests/pdo_037.phpt (revision e97d5fab)
1--TEST--
2Crash when calling a method of a class that inherits PDOStatement
3--SKIPIF--
4<?php
5if (!extension_loaded('pdo')) die('skip');
6?>
7--FILE--
8<?php
9
10class MyStatement extends PDOStatement
11{
12}
13
14$obj = new MyStatement;
15var_dump($obj->foo());
16
17?>
18--EXPECTF--
19Fatal error: Uncaught Error: Call to undefined method MyStatement::foo() in %s:%d
20Stack trace:
21#0 {main}
22  thrown in %s on line %d
23