- xmlrpc.inc: add support for the <ex:nil/> from the apache library, both in input...
[plcapi.git] / test / testsuite.php
index 08b7d91..5784be4 100644 (file)
@@ -14,6 +14,7 @@
        if ((int)ini_get('max_execution_time') < 180)
                ini_set('max_execution_time', 180);
 
+       ini_set('max_execution_time', 180);
 
        $suite = new PHPUnit_TestSuite();
 
                function setUp()
                {
                        global $DEBUG, $LOCALSERVER, $URI;
-                       $server = split(':', $LOCALSERVER);
+                       $server = explode(':', $LOCALSERVER);
                        if(count($server) > 1)
                        {
-                               $this->client=&new xmlrpc_client($URI, $server[0], $server[1]);
+                               $this->client=new xmlrpc_client($URI, $server[0], $server[1]);
                        }
                        else
                        {
-                               $this->client=&new xmlrpc_client($URI, $LOCALSERVER);
+                               $this->client=new xmlrpc_client($URI, $LOCALSERVER);
                        }
                        if($DEBUG)
                        {
@@ -1164,11 +1165,11 @@ and there they were.</value></member><member><name>postid</name><value>7414222</
                        $v1 = php_xmlrpc_encode($data, array('auto_dates'));
                        $v2 = php_xmlrpc_decode_xml($v1->serialize());
                        $this->assertEquals($v1, $v2);
-                       $r1 =& new xmlrpcresp($v1);
+                       $r1 = new xmlrpcresp($v1);
                        $r2 = php_xmlrpc_decode_xml($r1->serialize());
                        $r2->serialize(); // needed to set internal member payload
                        $this->assertEquals($r1, $r2);
-                       $m1 =& new xmlrpcmsg('hello dolly', array($v1));
+                       $m1 = new xmlrpcmsg('hello dolly', array($v1));
                        $m2 = php_xmlrpc_decode_xml($m1->serialize());
                        $m2->serialize(); // needed to set internal member payload
                        $this->assertEquals($m1, $m2);
@@ -1307,7 +1308,7 @@ $f = '<?xml version="1.0" encoding="utf-8"?><methodResponse><params><param><valu
                        $this->assertEquals(8, $r->faultCode());
 
                        // now test a successful connection
-                       $server = split(':', $LOCALSERVER);
+                       $server = explode(':', $LOCALSERVER);
                        if(count($server) > 1)
                        {
                                $this->client->port = $server[1];
@@ -1409,6 +1410,7 @@ $f = '<?xml version="1.0" encoding="utf-8"?><methodResponse><params><param><valu
                echo "<h3>Using lib version: $xmlrpcVersion on PHP version: ".phpversion()."</h3>\n";
                echo '<h3>Running '.$suite->testCount().' tests (some of which are multiple) against servers: http://'.htmlspecialchars($LOCALSERVER.$URI).' and https://'.htmlspecialchars($HTTPSSERVER.$HTTPSURI)."\n ...</h3>\n";
                flush();
+           ob_flush();
        }
        else
        {
@@ -1470,4 +1472,4 @@ Proxy Server: <input name="PROXY" size="30" value="<?php echo isset($PROXY) ? ht
 <?php
                echo $result->toHTML()."\n</body>\n</html>\n";
        }
-?>
+?>
\ No newline at end of file