Debian Codegraph @

storage/mroonga/vendor/groonga/bindings/php/tests/001.phpt

raw
1 --TEST--
2 groonga connection
3 --DESCRIPTION--
4 required: variables_order includes "E"
5 --SKIPIF--
6 <?php
7 if (!extension_loaded("groonga")) print "skip";
8 if (!getenv('GROONGA_TEST_HOST')) print "skip";
9 ?>
10 --FILE--
11 <?php
12 $host = getenv('GROONGA_TEST_HOST');
13 $port = getenv('GROONGA_TEST_PORT') ? getenv('GROONGA_TEST_PORT') : 10041;
14
15 $grn = grn_ctx_init();
16 grn_ctx_connect($grn, $host, $port) or die("cannot connect groong server ({$host}:{$port})");
17 grn_ctx_send($grn, 'table_list');
18 var_dump(grn_ctx_recv($grn));
19 grn_ctx_close($grn);
20 --EXPECTF--
21 array(1) {
22 [0]=>
23 array(2) {
24 [0]=>
25 int(0)
26 [1]=>
27 string(%d) "%s"
28 }
29 }