/** * test change / delete of account */ public function testChangeDeleteAccount() { $system = $this->_getSystemAccount(); unset($system['id']); $system['type'] = Felamimail_Model_Account::TYPE_USER; $account = $this->_json->saveAccount($system); $accountRecord = new Felamimail_Model_Account($account, TRUE); $accountRecord->resolveCredentials(FALSE); if (TestServer::getInstance()->getConfig()->mailserver) { $this->assertEquals(TestServer::getInstance()->getConfig()->mailserver, $account['host']); } $this->_json->changeCredentials($account['id'], $accountRecord->user, 'neuespasswort'); $account = $this->_json->getAccount($account['id']); $accountRecord = new Felamimail_Model_Account($account, TRUE); $accountRecord->resolveCredentials(FALSE); $this->assertEquals('neuespasswort', $accountRecord->password); $this->_json->deleteAccounts($account['id']); }