/** * List collections. * * @param array $options * @return array */ public function listCollections($options = null) { try { // TODO package this in Pages $domains = $this->_simpleDb->listDomains()->getData(); } catch (Zend_Service_Amazon_Exception $e) { throw new Zend_Cloud_DocumentService_Exception('Error on collection deletion: ' . $e->getMessage(), $e->getCode(), $e); } return $domains; }
public function testDeleteDomain() { $domainName = $this->_testDomainNamePrefix . '_testDeleteDomain'; $this->_amazon->deleteDomain($domainName); $this->_amazon->createDomain($domainName); try { $domainListPage = $this->_amazon->listDomains(); $this->assertContains($domainName, $domainListPage->getData()); $this->assertNull($domainListPage->getToken()); // Delete the domain $this->_amazon->deleteDomain($domainName); $domainListPage = $this->_amazon->listDomains(); $this->assertNotContains($domainName, $domainListPage->getData()); } catch(Exception $e) { $this->_amazon->deleteDomain($domainName); throw $e; } }