| Server IP : 208.122.213.31 / Your IP : 216.73.216.45 Web Server : Apache System : Linux msd6191.mjhst.com 4.18.0-553.137.1.el8_10.x86_64 #1 SMP Wed Jun 24 11:40:24 UTC 2026 x86_64 User : WHMCS_MIA_382 ( 1001) PHP Version : 7.4.33 Disable Function : NONE MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/share/postfixadmin/tests/ |
Upload File : |
<?php
abstract class RemoteTest extends \PHPUnit\Framework\TestCase {
protected $server_url = 'http://change.me/to/work'; // http://orange/david/postfixadmin/xmlrpc.php';
protected $username = 'user@example.com';
protected $password = 'password1';
/* xmlrpc objects... */
protected $user;
protected $vacation;
protected $alias;
protected $xmlrpc_client;
public function setUp() : void {
parent::setUp();
if ($this->server_url == 'http://change.me/to/work') {
$this->markTestSkipped("Test skipped; Configuration change to \$this->server_url required");
}
if (!class_exists('Zend_XmlRpc_Client', true)) {
$this->markTestSkipped("Test skipped; Zend_XmlRpc_Client not found");
}
$this->xmlrpc_client = new Zend_XmlRpc_Client($this->server_url);
$http_client = $this->xmlrpc_client->getHttpClient();
$http_client->setCookieJar();
$login_object = $this->xmlrpc_client->getProxy('login');
$success = $login_object->login($this->username, $this->password);
if (!$success) {
die("Failed to login to xmlrpc interface");
}
}
}
/* vim: set expandtab softtabstop=4 tabstop=4 shiftwidth=4: */