xref: /PHP-8.4/ext/reflection/tests/003.phpt (revision f8d79582)
1--TEST--
2ReflectionMethod::invoke() with base class method
3--FILE--
4<?php
5
6class Foo
7{
8    function Test()
9    {
10        echo __METHOD__ . "\n";
11    }
12}
13
14class Bar extends Foo
15{
16    function Test()
17    {
18        echo __METHOD__ . "\n";
19    }
20}
21
22$o = new Bar;
23$r = new ReflectionMethod('Foo','Test');
24
25$r->invoke($o);
26
27?>
28--EXPECT--
29Foo::Test
30