summaryrefslogtreecommitdiff
path: root/ext/enchant/tests/broker_describe.phpt
blob: c54e05b9e9c8e0dfd3ffa645a59aa89eacd7c172 (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
--TEST--
enchant_broker_describe() function
--CREDITS--
marcosptf - <marcosptf@yahoo.com.br>
--SKIPIF--
<?php
if(!extension_loaded('enchant')) die('skip, enchant not loader');
if(!enchant_broker_init()) die("failed, broker_init failure\n");
?>
--FILE--
<?php
$broker = enchant_broker_init();
$counter = 0;

if($broker) {
    echo("OK\n");
    $provider = enchant_broker_describe($broker);

    if (is_array($provider)) {
        echo("OK\n");

	if ((isset($provider[$counter]['name']) && isset($provider[$counter]['desc']) && isset($provider[$counter]['file']))) {
	   echo("OK\n");

	} else {
	   echo("failed, broker describe\n");

	}
    } else {
        echo "failed, brocker describe array \n";
    }

} else {
    echo("failed, broker_init failure\n");
}
?>
--EXPECT--
OK
OK
OK