php-src/Zend/tests/bug48215.phpt
Gabriel Caruso ded3d984c6 Use EXPECT instead of EXPECTF when possible
EXPECTF logic in run-tests.php is considerable, so let's avoid it.
2018-02-20 21:53:48 +01:00

37 lines
478 B
PHP

--TEST--
Bug #48215 - parent::method() calls __construct
--FILE--
<?php
class A
{
public function __construct() {
echo __METHOD__ . "\n";
}
protected function A()
{
echo __METHOD__ . "\n";
}
}
class B extends A
{
public function __construct() {
echo __METHOD__ . "\n";
parent::__construct();
}
public function A()
{
echo __METHOD__ . "\n";
parent::A();
}
}
$b = new B();
$b->A();
?>
===DONE===
--EXPECT--
B::__construct
A::__construct
B::A
A::A
===DONE===