summaryrefslogtreecommitdiff
path: root/ext/standard/tests/aggregation/deaggregate.phpt
blob: 5c551d75bd7fc671d5968489fef938df664b83d6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
--TEST--
deaggreating
--POST--
--GET--
--FILE--
<?php
include "ext/standard/tests/aggregation/aggregate.lib";

$obj = new simple();
aggregate($obj, 'helper');
aggregate($obj, 'mixin');
print_r(aggregation_info($obj));
deaggregate($obj, 'helper');
print_r(aggregation_info($obj));
deaggregate($obj);
var_dump(aggregation_info($obj));
?>
--EXPECT--
I'm alive!
Array
(
    [helper] => Array
        (
            [methods] => Array
                (
                    [0] => do_this
                    [1] => do_that
                    [2] => just_another_method
                )

            [properties] => Array
                (
                    [0] => my_prop
                    [1] => your_prop
                    [2] => our_prop
                )

        )

    [mixin] => Array
        (
            [methods] => Array
                (
                    [0] => mix_it
                )

            [properties] => Array
                (
                    [0] => mix
                )

        )

)
Array
(
    [mixin] => Array
        (
            [methods] => Array
                (
                    [0] => mix_it
                )

            [properties] => Array
                (
                    [0] => mix
                )

        )

)
bool(false)