cvs: pear /Net_IMAP/tests testIMAP.php
| From: | Sebastian Ebling | Date: | Mon, 05 Feb 2007 01:23:37 +0000 |
| Subject: | cvs: pear /Net_IMAP/tests testIMAP.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-44542@lists.php.net to get a copy of this message | ||
hudeldudel Mon Feb 5 01:23:37 2007 UTC
Modified files:
/pear/Net_IMAP/tests testIMAP.php
Log:
test QUOTA and ACL only if server has capability
http://cvs.php.net/viewvc.cgi/pear/Net_IMAP/tests/testIMAP.php?r1=1.8&r2=1.9&diff_format=u
Index: pear/Net_IMAP/tests/testIMAP.php
diff -u pear/Net_IMAP/tests/testIMAP.php:1.8 pear/Net_IMAP/tests/testIMAP.php:1.9
--- pear/Net_IMAP/tests/testIMAP.php:1.8 Wed Jan 31 03:52:34 2007
+++ pear/Net_IMAP/tests/testIMAP.php Mon Feb 5 01:23:37 2007
@@ -13,7 +13,7 @@
* @author Sebastian Ebling <hudeldudel@php.net>
* @copyright 2006 Sebastian Ebling
* @license http://www.gnu.org/copyleft/gpl.html
- * @version CVS: $Id: testIMAP.php,v 1.8 2007/01/31 03:52:34 hudeldudel Exp $
+ * @version CVS: $Id: testIMAP.php,v 1.9 2007/02/05 01:23:37 hudeldudel Exp $
* @link http://pear.php.net/package/Net_IMAP/
*/
@@ -213,7 +213,7 @@
$this->login();
// this mailbox name must not exist before
$mailboxname =
'INBOX'.$this->delimiter.'testMailboxExistöäüÃ';
-
+ $this->fixture->deleteMailbox($mailboxname);
$result = $this->fixture->mailboxExist($mailboxname);
$this->assertFalse($result, 'Mailbox should NOT exist');
@@ -223,6 +223,9 @@
$result = $this->fixture->mailboxExist($mailboxname);
$this->assertTrue($result, 'Mailbox should exist');
+ $result = $this->fixture->deleteMailbox($mailboxname);
+ $this->assertTrue($result, 'Can not delete Mailbox');
+
$this->logout();
}
@@ -305,15 +308,21 @@
public function testGetStorageQuotaRoot()
{
$this->login();
+ if (!$this->fixture->hasCapability('QUOTA')) {
+ return;
+ }
$this->fixture->selectMailbox('INBOX');
$result = $this->fixture->getStorageQuotaRoot();
- $this->assertTrue(!PEAR::isError($result), 'Can not get QuotaRoot');
+ $this->assertTrue(!PEAR::isError($result), 'Can not get StorageQuotaRoot');
$this->logout();
}
public function testGetACL()
{
$this->login();
+ if (!$this->fixture->hasCapability('ACL')) {
+ return;
+ }
$result = $this->fixture->getACL();
$this->assertTrue(!PEAR::isError($result), 'Can not get ACL');
$this->logout();