diff --git a/library/Zend/Captcha/ReCaptcha.php b/library/Zend/Captcha/ReCaptcha.php index cecb1f1a901..9a28321925a 100644 --- a/library/Zend/Captcha/ReCaptcha.php +++ b/library/Zend/Captcha/ReCaptcha.php @@ -216,7 +216,7 @@ public function generate() /** * Validate captcha * - * @see Zend_Validate_Interface::isValid() + * @see Zend\Validator::isValid() * @param mixed $value * @return boolean */ diff --git a/library/Zend/Filter/Encrypt/Openssl.php b/library/Zend/Filter/Encrypt/Openssl.php index 8c6642004ec..805e0340039 100644 --- a/library/Zend/Filter/Encrypt/Openssl.php +++ b/library/Zend/Filter/Encrypt/Openssl.php @@ -474,7 +474,7 @@ public function decrypt($value) // decompress after decryption if (!empty($this->_compression)) { require_once 'Zend/Filter/Decompress.php'; - $decompress = new \Zend\Filter\Decompress($this->_compression); + $decompress = new Decompress($this->_compression); $decrypted = $decompress->filter($decrypted); } diff --git a/library/Zend/Mail/AbstractProtocol.php b/library/Zend/Mail/AbstractProtocol.php index bea5790b6a1..938a14b2bde 100644 --- a/library/Zend/Mail/AbstractProtocol.php +++ b/library/Zend/Mail/AbstractProtocol.php @@ -79,7 +79,7 @@ abstract class AbstractProtocol /** - * Instance of Zend_Validate to check hostnames + * Instance of Zend\Validator\ValidatorChain to check hostnames * @var \Zend\Validator\ValidatorChain */ protected $_validHost; diff --git a/library/Zend/OAuth/Token.php b/library/Zend/OAuth/Token.php index 7ddc602b326..42b83902117 100644 --- a/library/Zend/OAuth/Token.php +++ b/library/Zend/OAuth/Token.php @@ -36,7 +36,7 @@ interface Token * @param HTTPUtility $utility * @return void */ - public function __construct($response = null, HTTPUtility $utility = null); + public function __construct(HTTPResponse $response = null, HTTPUtility $utility = null); /** * Retrieve an arbitrary named parameter from the token diff --git a/library/Zend/OAuth/Token/Request.php b/library/Zend/OAuth/Token/Request.php index 50fffc6e0e7..4025ff792a4 100644 --- a/library/Zend/OAuth/Token/Request.php +++ b/library/Zend/OAuth/Token/Request.php @@ -46,7 +46,7 @@ class Request extends AbstractToken * @param null|Zend\OAuth\Http\Utility $utility */ public function __construct( - $response = null, + HTTPResponse $response = null, HTTPUtility $utility = null ) { parent::__construct($response, $utility); diff --git a/library/Zend/Service/Akismet/Akismet.php b/library/Zend/Service/Akismet/Akismet.php index efec0ab50a6..1568bdd1d9d 100644 --- a/library/Zend/Service/Akismet/Akismet.php +++ b/library/Zend/Service/Akismet/Akismet.php @@ -31,7 +31,7 @@ * * @uses Zend_Http_Client * @uses Zend\Service\AbstractService - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @uses Zend_Uri * @uses Zend_Version * @category Zend @@ -101,7 +101,7 @@ public function getBlogUrl() * * @param string $blogUrl * @return Zend_Service_Akismet - * @throws Zend_Service_Exception if invalid URL provided + * @throws Zend\Service\Exception if invalid URL provided */ public function setBlogUrl($blogUrl) { @@ -172,7 +172,7 @@ public function getPort() * * @param int $port * @return Zend_Service_Akismet - * @throws Zend_Service_Exception if non-integer value provided + * @throws Zend\Service\Exception if non-integer value provided */ public function setPort($port) { @@ -201,7 +201,7 @@ public function getUserAgent() * * @param string $userAgent * @return Zend_Service_Akismet - * @throws Zend_Service_Exception with invalid user agent string + * @throws Zend\Service\Exception with invalid user agent string */ public function setUserAgent($userAgent) { @@ -273,7 +273,7 @@ public function verifyKey($key = null, $blog = null) * @param string $path * @param array $params * @return Zend_Http_Response - * @throws Zend_Service_Exception if missing user_ip or user_agent fields + * @throws Zend\Service\Exception if missing user_ip or user_agent fields */ protected function _makeApiCall($path, $params) { @@ -312,7 +312,7 @@ protected function _makeApiCall($path, $params) * * @param array $params * @return boolean - * @throws Zend_Service_Exception with invalid API key + * @throws Zend\Service\Exception with invalid API key */ public function isSpam($params) { @@ -342,7 +342,7 @@ public function isSpam($params) * * @param array $params * @return void - * @throws Zend_Service_Exception with invalid API key + * @throws Zend\Service\Exception with invalid API key */ public function submitSpam($params) { diff --git a/library/Zend/Service/Audioscrobbler/Audioscrobbler.php b/library/Zend/Service/Audioscrobbler/Audioscrobbler.php index 7a55676bd60..0072aad931b 100644 --- a/library/Zend/Service/Audioscrobbler/Audioscrobbler.php +++ b/library/Zend/Service/Audioscrobbler/Audioscrobbler.php @@ -29,7 +29,7 @@ /** * @uses Zend_Http_Client * @uses Zend_Http_Client_Exception - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @category Zend * @package Zend_Service * @subpackage Audioscrobbler diff --git a/library/Zend/Service/Delicious/Exception.php b/library/Zend/Service/Delicious/Exception.php index 3c08571ba1e..2d2c4d295e5 100644 --- a/library/Zend/Service/Delicious/Exception.php +++ b/library/Zend/Service/Delicious/Exception.php @@ -25,7 +25,7 @@ namespace Zend\Service\Delicious; /** - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @category Zend * @package Zend_Service * @subpackage Delicious diff --git a/library/Zend/Service/DeveloperGarden/Client/Soap.php b/library/Zend/Service/DeveloperGarden/Client/Soap.php index 12aec10d300..465ac7a2e72 100644 --- a/library/Zend/Service/DeveloperGarden/Client/Soap.php +++ b/library/Zend/Service/DeveloperGarden/Client/Soap.php @@ -31,7 +31,7 @@ * @author Marco Kaiser * @license http://framework.zend.com/license/new-bsd New BSD License */ -class Zend_Service_DeveloperGarden_Client_Soap extends Zend_Soap_Client +class Zend_Service_DeveloperGarden_Client_Soap extends Zend\Soap\Client { /** * class with credential interface diff --git a/library/Zend/Service/DeveloperGarden/ConferenceCall/Participant.php b/library/Zend/Service/DeveloperGarden/ConferenceCall/Participant.php index 3b8e5470875..84e86e26de3 100644 --- a/library/Zend/Service/DeveloperGarden/ConferenceCall/Participant.php +++ b/library/Zend/Service/DeveloperGarden/ConferenceCall/Participant.php @@ -20,7 +20,6 @@ */ /** - * @uses Zend_Validate_Ip * @category Zend * @package Zend_Service * @subpackage DeveloperGarden diff --git a/library/Zend/Service/DeveloperGarden/ConferenceCall/ParticipantDetail.php b/library/Zend/Service/DeveloperGarden/ConferenceCall/ParticipantDetail.php index 4569058ce72..4b8c6c4fae8 100644 --- a/library/Zend/Service/DeveloperGarden/ConferenceCall/ParticipantDetail.php +++ b/library/Zend/Service/DeveloperGarden/ConferenceCall/ParticipantDetail.php @@ -20,7 +20,7 @@ */ /** - * @uses Zend_Validate_EmailAddress + * @uses Zend\Validator\EmailAddress * @uses Zend_Service_DeveloperGarden_Exception * @category Zend * @package Zend_Service @@ -158,7 +158,7 @@ public function getEmail() */ public function setEmail($email) { - $validator = new Zend_Validate_EmailAddress(); + $validator = new Zend\Validator\EmailAddress(); if (!$validator->isValid($email)) { throw new Zend_Service_DeveloperGarden_Exception('Not a valid e-mail address.'); diff --git a/library/Zend/Service/DeveloperGarden/ConferenceCall/ParticipantStatus.php b/library/Zend/Service/DeveloperGarden/ConferenceCall/ParticipantStatus.php index f54776f3e03..c3b42829bf6 100644 --- a/library/Zend/Service/DeveloperGarden/ConferenceCall/ParticipantStatus.php +++ b/library/Zend/Service/DeveloperGarden/ConferenceCall/ParticipantStatus.php @@ -20,7 +20,6 @@ */ /** - * @uses Zend_Validate_Ip * @category Zend * @package Zend_Service * @subpackage DeveloperGarden diff --git a/library/Zend/Service/DeveloperGarden/Exception.php b/library/Zend/Service/DeveloperGarden/Exception.php index d6cd7a3357e..2e06b2a046f 100644 --- a/library/Zend/Service/DeveloperGarden/Exception.php +++ b/library/Zend/Service/DeveloperGarden/Exception.php @@ -20,7 +20,7 @@ */ /** - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @category Zend * @package Zend_Service * @subpackage DeveloperGarden @@ -28,6 +28,6 @@ * @author Marco Kaiser * @license http://framework.zend.com/license/new-bsd New BSD License */ -class Zend_Service_DeveloperGarden_Exception extends Zend_Service_Exception +class Zend_Service_DeveloperGarden_Exception extends Zend\Service\Exception { } diff --git a/library/Zend/Service/DeveloperGarden/IpLocation/IpAddress.php b/library/Zend/Service/DeveloperGarden/IpLocation/IpAddress.php index 135e3b0012a..68747d32230 100644 --- a/library/Zend/Service/DeveloperGarden/IpLocation/IpAddress.php +++ b/library/Zend/Service/DeveloperGarden/IpLocation/IpAddress.php @@ -20,7 +20,7 @@ */ /** - * @uses Zend_Validate_Ip + * @uses Zend\Validator\Ip * @uses Zend_Service_DeveloperGarden_Exception * @category Zend * @package Zend_Service @@ -75,7 +75,7 @@ public function __construct($ip, $version = 4) */ public function setIp($ip) { - $validator = new Zend_Validate_Ip(); + $validator = new Zend\Validator\Ip(); if (!$validator->isValid($ip)) { $message = $validator->getMessages(); diff --git a/library/Zend/Service/DeveloperGarden/LocalSearch/SearchParameters.php b/library/Zend/Service/DeveloperGarden/LocalSearch/SearchParameters.php index a1a3a449844..acecbe3f4a4 100644 --- a/library/Zend/Service/DeveloperGarden/LocalSearch/SearchParameters.php +++ b/library/Zend/Service/DeveloperGarden/LocalSearch/SearchParameters.php @@ -21,9 +21,9 @@ /** * @uses Zend_Service_DeveloperGarden_LocalSearch_Exception - * @uses Zend_Validate_Between - * @uses Zend_Validate_Int - * @uses Zend_Validate_NotEmpty + * @uses Zend\Validator\Between + * @uses Zend\Validator\Int + * @uses Zend\Validator\NotEmpty * @category Zend * @package Zend_Service * @subpackage DeveloperGarden @@ -178,7 +178,7 @@ public function disableDidYouMeanRelated() */ public function setHits($hits = 10) { - $validator = new Zend_Validate_Between(0, 1000); + $validator = new Zend\Validator\Between(0, 1000); if (!$validator->isValid($hits)) { $message = $validator->getMessages(); throw new Zend_Service_DeveloperGarden_LocalSearch_Exception(current($message)); @@ -221,7 +221,7 @@ public function setCollapse($value) */ public function setWhere($where) { - $validator = new Zend_Validate_NotEmpty(); + $validator = new Zend\Validator\NotEmpty(); if (!$validator->isValid($where)) { $message = $validator->getMessages(); throw new Zend_Service_DeveloperGarden_LocalSearch_Exception(current($message)); @@ -270,7 +270,7 @@ public function disableSpatial() */ public function setRadius($radius) { - $validator = new Zend_Validate_Int(); + $validator = new Zend\Validator\Int(); if (!$validator->isValid($radius)) { $message = $validator->getMessages(); throw new Zend_Service_DeveloperGarden_LocalSearch_Exception(current($message)); diff --git a/library/Zend/Service/Flickr.php b/library/Zend/Service/Flickr.php index 5b4004680bb..00c3192c204 100644 --- a/library/Zend/Service/Flickr.php +++ b/library/Zend/Service/Flickr.php @@ -23,11 +23,11 @@ * @uses DOMDocument * @uses DOMXPath * @uses Zend_Rest_Client - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @uses Zend_Service_Flickr_Image * @uses Zend_Service_Flickr_ResultSet - * @uses Zend_Validate_Between - * @uses Zend_Validate_Int + * @uses Zend\Validator\Between + * @uses Zend\Validator\Int * @category Zend * @package Zend_Service * @subpackage Flickr @@ -88,7 +88,7 @@ public function __construct($apiKey) * @param string|array $query A single tag or an array of tags. * @param array $options Additional parameters to refine your query. * @return Zend_Service_Flickr_ResultSet - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function tagSearch($query, array $options = array()) { @@ -110,7 +110,7 @@ public function tagSearch($query, array $options = array()) $response = $restClient->restGet('/services/rest/', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -138,7 +138,7 @@ public function tagSearch($query, array $options = array()) * @param string $query username or email * @param array $options Additional parameters to refine your query. * @return Zend_Service_Flickr_ResultSet - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function userSearch($query, array $options = null) { @@ -166,7 +166,7 @@ public function userSearch($query, array $options = null) $response = $restClient->restGet('/services/rest/', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -184,7 +184,7 @@ public function userSearch($query, array $options = null) * @param string $query group id * @param array $options Additional parameters to refine your query. * @return Zend_Service_Flickr_ResultSet - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function groupPoolGetPhotos($query, array $options = array()) { @@ -194,7 +194,7 @@ public function groupPoolGetPhotos($query, array $options = array()) 'extras' => 'license, date_upload, date_taken, owner_name, icon_server'); if (empty($query) || !is_string($query)) { - throw new Zend_Service_Exception('You must supply a group id'); + throw new Zend\Service\Exception('You must supply a group id'); } $options['group_id'] = $query; @@ -209,7 +209,7 @@ public function groupPoolGetPhotos($query, array $options = array()) $response = $restClient->restGet('/services/rest/', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -230,7 +230,7 @@ public function groupPoolGetPhotos($query, array $options = array()) * * @param string $username the username * @return string the NSID (userid) - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function getIdByUsername($username) { @@ -239,7 +239,7 @@ public function getIdByUsername($username) $options = array('api_key' => $this->apiKey, 'method' => $method, 'username' => (string) $username); if (empty($username)) { - throw new Zend_Service_Exception('You must supply a username'); + throw new Zend\Service\Exception('You must supply a username'); } $restClient = $this->getRestClient(); @@ -247,7 +247,7 @@ public function getIdByUsername($username) $response = $restClient->restGet('/services/rest/', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -266,14 +266,14 @@ public function getIdByUsername($username) * * @param string $email the email * @return string the NSID (userid) - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function getIdByEmail($email) { static $method = 'flickr.people.findByEmail'; if (empty($email)) { - throw new Zend_Service_Exception('You must supply an e-mail address'); + throw new Zend\Service\Exception('You must supply an e-mail address'); } $options = array('api_key' => $this->apiKey, 'method' => $method, 'find_email' => (string) $email); @@ -283,7 +283,7 @@ public function getIdByEmail($email) $response = $restClient->restGet('/services/rest/', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -300,14 +300,14 @@ public function getIdByEmail($email) * * @param string $id the NSID * @return array of Zend_Service_Flickr_Image, details for the specified image - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function getImageDetails($id) { static $method = 'flickr.photos.getSizes'; if (empty($id)) { - throw new Zend_Service_Exception('You must supply a photo ID'); + throw new Zend\Service\Exception('You must supply a photo ID'); } $options = array('api_key' => $this->apiKey, 'method' => $method, 'photo_id' => $id); @@ -338,7 +338,7 @@ public function getImageDetails($id) public function getRestClient() { if (null === $this->_restClient) { - $this->_restClient = new Zend_Rest_Client(self::URI_BASE); + $this->_restClient = new Zend\Rest\Client\RestClient(self::URI_BASE); } return $this->_restClient; @@ -350,7 +350,7 @@ public function getRestClient() * * @param array $options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateUserSearch(array $options) { @@ -359,14 +359,14 @@ protected function _validateUserSearch(array $options) $this->_compareOptions($options, $validOptions); - $between = new Zend_Validate_Between(1, 500, true); + $between = new Zend\Validator\Between(1, 500, true); if (!$between->isValid($options['per_page'])) { - throw new Zend_Service_Exception($options['per_page'] . ' is not valid for the "per_page" option'); + throw new Zend\Service\Exception($options['per_page'] . ' is not valid for the "per_page" option'); } - $int = new Zend_Validate_Int(); + $int = new Zend\Validator\Int(); if (!$int->isValid($options['page'])) { - throw new Zend_Service_Exception($options['page'] . ' is not valid for the "page" option'); + throw new Zend\Service\Exception($options['page'] . ' is not valid for the "page" option'); } // validate extras, which are delivered in csv format @@ -388,7 +388,7 @@ protected function _validateUserSearch(array $options) * * @param array $options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateTagSearch(array $options) { @@ -401,14 +401,14 @@ protected function _validateTagSearch(array $options) $this->_compareOptions($options, $validOptions); - $between = new Zend_Validate_Between(1, 500, true); + $between = new Zend\Validator\Between(1, 500, true); if (!$between->isValid($options['per_page'])) { - throw new Zend_Service_Exception($options['per_page'] . ' is not valid for the "per_page" option'); + throw new Zend\Service\Exception($options['per_page'] . ' is not valid for the "per_page" option'); } - $int = new Zend_Validate_Int(); + $int = new Zend\Validator\Int(); if (!$int->isValid($options['page'])) { - throw new Zend_Service_Exception($options['page'] . ' is not valid for the "page" option'); + throw new Zend\Service\Exception($options['page'] . ' is not valid for the "page" option'); } // validate extras, which are delivered in csv format @@ -430,7 +430,7 @@ protected function _validateTagSearch(array $options) * Validate Group Search Options * * @param array $options - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception * @return void */ protected function _validateGroupPoolGetPhotos(array $options) @@ -439,15 +439,15 @@ protected function _validateGroupPoolGetPhotos(array $options) $this->_compareOptions($options, $validOptions); - $between = new Zend_Validate_Between(1, 500, true); + $between = new Zend\Validator\Between(1, 500, true); if (!$between->isValid($options['per_page'])) { - throw new Zend_Service_Exception($options['per_page'] . ' is not valid for the "per_page" option'); + throw new Zend\Service\Exception($options['per_page'] . ' is not valid for the "per_page" option'); } - $int = new Zend_Validate_Int(); + $int = new Zend\Validator\Int(); if (!$int->isValid($options['page'])) { - throw new Zend_Service_Exception($options['page'] . ' is not valid for the "page" option'); + throw new Zend\Service\Exception($options['page'] . ' is not valid for the "page" option'); } // validate extras, which are delivered in csv format @@ -469,14 +469,14 @@ protected function _validateGroupPoolGetPhotos(array $options) * * @param DOMDocument $dom * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected static function _checkErrors(DOMDocument $dom) { if ($dom->documentElement->getAttribute('stat') === 'fail') { $xpath = new DOMXPath($dom); $err = $xpath->query('//err')->item(0); - throw new Zend_Service_Exception('Search failed due to error: ' . $err->getAttribute('msg') + throw new Zend\Service\Exception('Search failed due to error: ' . $err->getAttribute('msg') . ' (error #' . $err->getAttribute('code') . ')'); } } @@ -505,13 +505,13 @@ protected function _prepareOptions($method, array $options, array $defaultOption * @param array $options User options * @param array $validOptions Valid options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _compareOptions(array $options, array $validOptions) { $difference = array_diff(array_keys($options), $validOptions); if ($difference) { - throw new Zend_Service_Exception('The following parameters are invalid: ' . implode(',', $difference)); + throw new Zend\Service\Exception('The following parameters are invalid: ' . implode(',', $difference)); } } } diff --git a/library/Zend/Service/Nirvanix.php b/library/Zend/Service/Nirvanix.php index 3f6f54919e3..de93bbe5760 100644 --- a/library/Zend/Service/Nirvanix.php +++ b/library/Zend/Service/Nirvanix.php @@ -53,7 +53,7 @@ public function __construct($authParams, $options = array()) { // merge options with default options $defaultOptions = array('defaults' => array(), - 'httpClient' => new Zend_Http_Client(), + 'httpClient' => new Zend\Http\Client(), 'host' => 'http://services.nirvanix.com'); $this->_options = array_merge($defaultOptions, $options); diff --git a/library/Zend/Service/Nirvanix/Exception.php b/library/Zend/Service/Nirvanix/Exception.php index 0ad7071071b..5bed79648d1 100644 --- a/library/Zend/Service/Nirvanix/Exception.php +++ b/library/Zend/Service/Nirvanix/Exception.php @@ -20,12 +20,12 @@ */ /** - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @category Zend * @package Zend_Service * @subpackage Nirvanix * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ -class Zend_Service_Nirvanix_Exception extends Zend_Service_Exception +class Zend_Service_Nirvanix_Exception extends Zend\Service\Exception {} diff --git a/library/Zend/Service/Nirvanix/Namespace/Base.php b/library/Zend/Service/Nirvanix/Namespace/Base.php index 0cd6c984960..e2991362050 100644 --- a/library/Zend/Service/Nirvanix/Namespace/Base.php +++ b/library/Zend/Service/Nirvanix/Namespace/Base.php @@ -84,7 +84,7 @@ public function __construct($options = array()) } if (! isset($options['httpClient'])) { - $options['httpClient'] = new Zend_Http_Client(); + $options['httpClient'] = new Zend\Http\Client(); } $this->_httpClient = $options['httpClient']; } @@ -120,7 +120,7 @@ public function __call($methodName, $args) $this->_httpClient->resetParameters(); $this->_httpClient->setParameterPost($params); - $httpResponse = $this->_httpClient->request(Zend_Http_Client::POST); + $httpResponse = $this->_httpClient->request(Zend\Http\Client::POST); return $this->_wrapResponse($httpResponse); } diff --git a/library/Zend/Service/Nirvanix/Namespace/Imfs.php b/library/Zend/Service/Nirvanix/Namespace/Imfs.php index d690d33b0b1..9cb3048d427 100644 --- a/library/Zend/Service/Nirvanix/Namespace/Imfs.php +++ b/library/Zend/Service/Nirvanix/Namespace/Imfs.php @@ -53,7 +53,7 @@ public function getContents($filePath, $expiration = 3600) // download the file $this->_httpClient->resetParameters(); $this->_httpClient->setUri($url); - $resp = $this->_httpClient->request(Zend_Http_Client::GET); + $resp = $this->_httpClient->request(Zend\Http\Client::GET); return $resp->getBody(); } @@ -81,7 +81,7 @@ public function putContents($filePath, $data, $mimeType = null) $this->_httpClient->setParameterPost('uploadToken', $uploadToken); $this->_httpClient->setParameterPost('destFolderPath', str_replace('\\', '/',dirname($filePath))); $this->_httpClient->setFileUpload(basename($filePath), 'uploadFile', $data, $mimeType); - $response = $this->_httpClient->request(Zend_Http_Client::POST); + $response = $this->_httpClient->request(Zend\Http\Client::POST); return new Zend_Service_Nirvanix_Response($response->getBody()); } diff --git a/library/Zend/Service/Simpy.php b/library/Zend/Service/Simpy.php index 0dd8acad1ad..1a8dfb0bef2 100644 --- a/library/Zend/Service/Simpy.php +++ b/library/Zend/Service/Simpy.php @@ -23,7 +23,7 @@ * @uses DOMDocument * @uses DOMXPath * @uses Zend_Http_Client - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @uses Zend_Service_Simpy_LinkSet * @uses Zend_Service_Simpy_NoteSet * @uses Zend_Service_Simpy_TagSet @@ -81,7 +81,7 @@ public function getHttpClient() * * @param string $op Name of the operation for the request * @param array $query Query data for the request (optional) - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception * @return DOMDocument Parsed XML response */ protected function _makeRequest($op, $query = null) @@ -106,14 +106,14 @@ protected function _makeRequest($op, $query = null) if ($code != 0) { $list = $xpath->query('/status/message'); $message = $list->item(0)->nodeValue; - throw new Zend_Service_Exception($message, $code); + throw new Zend\Service\Exception($message, $code); } } return $doc; } - throw new Zend_Service_Exception($response->getMessage(), $response->getStatus()); + throw new Zend\Service\Exception($response->getMessage(), $response->getStatus()); } /** @@ -122,7 +122,7 @@ protected function _makeRequest($op, $query = null) * * @param int $limit Limits the number of tags returned (optional) * @link http://www.simpy.com/doc/api/rest/GetTags - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception * @return Zend_Service_Simpy_TagSet */ public function getTags($limit = null) diff --git a/library/Zend/Service/SlideShare/Exception.php b/library/Zend/Service/SlideShare/Exception.php index 43e79c183d4..a2dc991a06e 100644 --- a/library/Zend/Service/SlideShare/Exception.php +++ b/library/Zend/Service/SlideShare/Exception.php @@ -32,4 +32,5 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ interface Exception -{} +{ +} diff --git a/library/Zend/Service/StrikeIron/Exception.php b/library/Zend/Service/StrikeIron/Exception.php index d16a6750120..b6eaaf4ac4b 100644 --- a/library/Zend/Service/StrikeIron/Exception.php +++ b/library/Zend/Service/StrikeIron/Exception.php @@ -20,12 +20,12 @@ */ /** - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @category Zend * @package Zend_Service * @subpackage StrikeIron * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ -class Zend_Service_StrikeIron_Exception extends Zend_Service_Exception +class Zend_Service_StrikeIron_Exception extends Zend\Service\Exception {} diff --git a/library/Zend/Service/Technorati/Exception.php b/library/Zend/Service/Technorati/Exception.php index 52998c0b0e1..c5629af9b06 100644 --- a/library/Zend/Service/Technorati/Exception.php +++ b/library/Zend/Service/Technorati/Exception.php @@ -20,13 +20,13 @@ */ /** - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @category Zend * @package Zend_Service * @subpackage Technorati * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ -class Zend_Service_Technorati_Exception extends Zend_Service_Exception +class Zend_Service_Technorati_Exception extends Zend\Service\Exception { } diff --git a/library/Zend/Service/Technorati/ResultSet.php b/library/Zend/Service/Technorati/ResultSet.php index 2e7d907408a..db76d7018cc 100644 --- a/library/Zend/Service/Technorati/ResultSet.php +++ b/library/Zend/Service/Technorati/ResultSet.php @@ -180,7 +180,7 @@ public function totalResultsAvailable() * Implements SeekableIterator::current(). * * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception * @abstract */ // abstract public function current(); diff --git a/library/Zend/Service/WindowsAzure/Exception.php b/library/Zend/Service/WindowsAzure/Exception.php index 42db6e31d43..a20bfee10b0 100644 --- a/library/Zend/Service/WindowsAzure/Exception.php +++ b/library/Zend/Service/WindowsAzure/Exception.php @@ -20,11 +20,11 @@ */ /** - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @category Zend * @package Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ -class Zend_Service_WindowsAzure_Exception extends Zend_Service_Exception +class Zend_Service_WindowsAzure_Exception extends Zend\Service\Exception {} diff --git a/library/Zend/Service/WindowsAzure/Storage.php b/library/Zend/Service/WindowsAzure/Storage.php index 81535b7dcfc..891b552f3f7 100644 --- a/library/Zend/Service/WindowsAzure/Storage.php +++ b/library/Zend/Service/WindowsAzure/Storage.php @@ -20,8 +20,8 @@ */ /** - * @uses Zend_Http_Client - * @uses Zend_Http_Response + * @uses Zend\Http\Client + * @uses Zend\Http\Response * @uses Zend_Service_WindowsAzure_Credentials_AbstractCredentials * @uses Zend_Service_WindowsAzure_Credentials_SharedKey * @uses Zend_Service_WindowsAzure_Exception @@ -186,7 +186,7 @@ public function __construct( // Setup default Zend_Http_Client channel $options = array( - 'adapter' => 'Zend_Http_Client_Adapter_Proxy' + 'adapter' => 'Zend\\Http\\Client\\Adapter\\Proxy' ); if (function_exists('curl_init')) { // Set cURL options if cURL is used afterwards @@ -195,7 +195,7 @@ public function __construct( CURLOPT_TIMEOUT => 120, ); } - $this->_httpClientChannel = new Zend_Http_Client(null, $options); + $this->_httpClientChannel = new Zend\Http\Client(null, $options); } /** @@ -203,7 +203,7 @@ public function __construct( * * @param Zend_Http_Client_Adapter_Interface|string $adapterInstance Adapter instance or adapter class name. */ - public function setHttpClientChannel($adapterInstance = 'Zend_Http_Client_Adapter_Proxy') + public function setHttpClientChannel($adapterInstance = 'Zend\\Http\\Client\\Adapter\\Proxy') { $this->_httpClientChannel->setAdapter($adapterInstance); } @@ -320,7 +320,7 @@ public function getCredentials() protected function _performRequest( $path = '/', $queryString = '', - $httpVerb = Zend_Http_Client::GET, + $httpVerb = Zend\Http\Client::GET, $headers = array(), $forTableStorage = false, $rawData = null, @@ -380,7 +380,7 @@ protected function _performRequest( * @return object * @throws Zend_Service_WindowsAzure_Exception */ - protected function _parseResponse(Zend_Http_Response $response = null) + protected function _parseResponse(Zend\Http\Response $response = null) { if ($response === null) { throw new Zend_Service_WindowsAzure_Exception('Response should not be null.'); diff --git a/library/Zend/Service/WindowsAzure/Storage/Blob.php b/library/Zend/Service/WindowsAzure/Storage/Blob.php index c6615ddc05b..6477ec2175b 100644 --- a/library/Zend/Service/WindowsAzure/Storage/Blob.php +++ b/library/Zend/Service/WindowsAzure/Storage/Blob.php @@ -20,8 +20,8 @@ */ /** - * @uses Zend_Http_Client - * @uses Zend_Http_Response + * @uses Zend\Http\Client + * @uses Zend\Http\Response * @uses Zend_Service_WindowsAzure_Credentials_AbstractCredentials * @uses Zend_Service_WindowsAzure_Credentials_SharedAccessSignature * @uses Zend_Service_WindowsAzure_Exception @@ -174,7 +174,7 @@ public function createContainer($containerName = '', $metadata = array()) $headers = array_merge($headers, $this->_generateMetadataHeaders($metadata)); // Perform request - $response = $this->_performRequest($containerName, '?restype=container', Zend_Http_Client::PUT, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($containerName, '?restype=container', Zend\Http\Client::PUT, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if ($response->isSuccessful()) { return new Zend_Service_WindowsAzure_Storage_BlobContainer( $containerName, @@ -205,7 +205,7 @@ public function getContainerAcl($containerName = '', $signedIdentifiers = false) } // Perform request - $response = $this->_performRequest($containerName, '?restype=container&comp=acl', Zend_Http_Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); + $response = $this->_performRequest($containerName, '?restype=container&comp=acl', Zend\Http\Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); if ($response->isSuccessful()) { if ($signedIdentifiers == false) { // Only public/private @@ -285,7 +285,7 @@ public function setContainerAcl($containerName = '', $acl = self::ACL_PRIVATE, $ } // Perform request - $response = $this->_performRequest($containerName, '?restype=container&comp=acl', Zend_Http_Client::PUT, array('x-ms-prop-publicaccess' => $acl), false, $policies, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($containerName, '?restype=container&comp=acl', Zend\Http\Client::PUT, array('x-ms-prop-publicaccess' => $acl), false, $policies, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if (!$response->isSuccessful()) { throw new Zend_Service_WindowsAzure_Exception($this->_getErrorMessage($response, 'Resource could not be accessed.')); } @@ -308,7 +308,7 @@ public function getContainer($containerName = '') } // Perform request - $response = $this->_performRequest($containerName, '?restype=container', Zend_Http_Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); + $response = $this->_performRequest($containerName, '?restype=container', Zend\Http\Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); if ($response->isSuccessful()) { // Parse metadata $metadata = $this->_parseMetadataHeaders($response->getHeaders()); @@ -379,7 +379,7 @@ public function setContainerMetadata($containerName = '', $metadata = array(), $ } // Perform request - $response = $this->_performRequest($containerName, '?restype=container&comp=metadata', Zend_Http_Client::PUT, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($containerName, '?restype=container&comp=metadata', Zend\Http\Client::PUT, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if (!$response->isSuccessful()) { throw new Zend_Service_WindowsAzure_Exception($this->_getErrorMessage($response, 'Resource could not be accessed.')); } @@ -408,7 +408,7 @@ public function deleteContainer($containerName = '', $additionalHeaders = array( } // Perform request - $response = $this->_performRequest($containerName, '?restype=container', Zend_Http_Client::DELETE, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($containerName, '?restype=container', Zend\Http\Client::DELETE, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if (!$response->isSuccessful()) { throw new Zend_Service_WindowsAzure_Exception($this->_getErrorMessage($response, 'Resource could not be accessed.')); } @@ -439,7 +439,7 @@ public function listContainers($prefix = null, $maxResults = null, $marker = nul } // Perform request - $response = $this->_performRequest('', $queryString, Zend_Http_Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_LIST); + $response = $this->_performRequest('', $queryString, Zend\Http\Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_CONTAINER, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_LIST); if ($response->isSuccessful()) { $xmlContainers = $this->_parseResponse($response)->Containers->Container; $xmlMarker = (string)$this->_parseResponse($response)->NextMarker; @@ -523,7 +523,7 @@ public function putBlob($containerName = '', $blobName = '', $localFileName = '' $resourceName = self::createResourceName($containerName , $blobName); // Perform request - $response = $this->_performRequest($resourceName, '', Zend_Http_Client::PUT, $headers, false, $fileContents, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($resourceName, '', Zend\Http\Client::PUT, $headers, false, $fileContents, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if ($response->isSuccessful()) { return new Zend_Service_WindowsAzure_Storage_BlobInstance( $containerName, @@ -651,7 +651,7 @@ public function putBlock($containerName = '', $blobName = '', $identifier = '', $resourceName = self::createResourceName($containerName , $blobName); // Upload - $response = $this->_performRequest($resourceName, '?comp=block&blockid=' . base64_encode($identifier), Zend_Http_Client::PUT, null, false, $contents, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($resourceName, '?comp=block&blockid=' . base64_encode($identifier), Zend\Http\Client::PUT, null, false, $contents, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if (!$response->isSuccessful()) { throw new Zend_Service_WindowsAzure_Exception($this->_getErrorMessage($response, 'Resource could not be accessed.')); } @@ -712,7 +712,7 @@ public function putBlockList($containerName = '', $blobName = '', $blockList = a $resourceName = self::createResourceName($containerName , $blobName); // Perform request - $response = $this->_performRequest($resourceName, '?comp=blocklist', Zend_Http_Client::PUT, $headers, false, $fileContents, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($resourceName, '?comp=blocklist', Zend\Http\Client::PUT, $headers, false, $fileContents, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if (!$response->isSuccessful()) { throw new Zend_Service_WindowsAzure_Exception($this->_getErrorMessage($response, 'Resource could not be accessed.')); } @@ -755,7 +755,7 @@ public function getBlockList($containerName = '', $blobName = '', $type = 0) $resourceName = self::createResourceName($containerName , $blobName); // Perform request - $response = $this->_performRequest($resourceName, '?comp=blocklist&blocklisttype=' . $blockListType, Zend_Http_Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); + $response = $this->_performRequest($resourceName, '?comp=blocklist&blocklisttype=' . $blockListType, Zend\Http\Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); if ($response->isSuccessful()) { // Parse response $blockList = $this->_parseResponse($response); @@ -841,7 +841,7 @@ public function copyBlob($sourceContainerName = '', $sourceBlobName = '', $desti $headers["x-ms-copy-source"] = '/' . $this->_accountName . '/' . $sourceResourceName; // Perform request - $response = $this->_performRequest($destinationResourceName, '', Zend_Http_Client::PUT, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($destinationResourceName, '', Zend\Http\Client::PUT, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if ($response->isSuccessful()) { return new Zend_Service_WindowsAzure_Storage_BlobInstance( $destinationContainerName, @@ -895,7 +895,7 @@ public function getBlob($containerName = '', $blobName = '', $localFileName = '' $resourceName = self::createResourceName($containerName , $blobName); // Perform request - $response = $this->_performRequest($resourceName, '', Zend_Http_Client::GET, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); + $response = $this->_performRequest($resourceName, '', Zend\Http\Client::GET, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); if ($response->isSuccessful()) { file_put_contents($localFileName, $response->getBody()); } else { @@ -937,7 +937,7 @@ public function getBlobInstance($containerName = '', $blobName = '', $additional $resourceName = self::createResourceName($containerName , $blobName); // Perform request - $response = $this->_performRequest($resourceName, '', Zend_Http_Client::HEAD, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); + $response = $this->_performRequest($resourceName, '', Zend\Http\Client::HEAD, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_READ); if ($response->isSuccessful()) { // Parse metadata $metadata = $this->_parseMetadataHeaders($response->getHeaders()); @@ -1026,7 +1026,7 @@ public function setBlobMetadata($containerName = '', $blobName = '', $metadata = } // Perform request - $response = $this->_performRequest($containerName . '/' . $blobName, '?comp=metadata', Zend_Http_Client::PUT, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($containerName . '/' . $blobName, '?comp=metadata', Zend\Http\Client::PUT, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if (!$response->isSuccessful()) { throw new Zend_Service_WindowsAzure_Exception($this->_getErrorMessage($response, 'Resource could not be accessed.')); } @@ -1065,7 +1065,7 @@ public function deleteBlob($containerName = '', $blobName = '', $additionalHeade $resourceName = self::createResourceName($containerName , $blobName); // Perform request - $response = $this->_performRequest($resourceName, '', Zend_Http_Client::DELETE, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); + $response = $this->_performRequest($resourceName, '', Zend\Http\Client::DELETE, $headers, false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_WRITE); if (!$response->isSuccessful()) { throw new Zend_Service_WindowsAzure_Exception($this->_getErrorMessage($response, 'Resource could not be accessed.')); } @@ -1108,7 +1108,7 @@ public function listBlobs($containerName = '', $prefix = '', $delimiter = '', $m } // Perform request - $response = $this->_performRequest($containerName, $queryString, Zend_Http_Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_LIST); + $response = $this->_performRequest($containerName, $queryString, Zend\Http\Client::GET, array(), false, null, Zend_Service_WindowsAzure_Storage::RESOURCE_BLOB, Zend_Service_WindowsAzure_Credentials_AbstractCredentials::PERMISSION_LIST); if ($response->isSuccessful()) { // Return value $blobs = array(); @@ -1321,13 +1321,13 @@ public static function isValidContainerName($containerName = '') } /** - * Get error message from Zend_Http_Response + * Get error message from Zend\Http\Response * - * @param Zend_Http_Response $response Repsonse + * @param Zend\Http\Response $response Repsonse * @param string $alternativeError Alternative error message * @return string */ - protected function _getErrorMessage(Zend_Http_Response $response, $alternativeError = 'Unknown error.') + protected function _getErrorMessage(Zend\Http\Response $response, $alternativeError = 'Unknown error.') { $response = $this->_parseResponse($response); if ($response && $response->Message) { diff --git a/library/Zend/Service/Yahoo.php b/library/Zend/Service/Yahoo.php index 304bfd773f0..5e6fe16f5cb 100644 --- a/library/Zend/Service/Yahoo.php +++ b/library/Zend/Service/Yahoo.php @@ -23,7 +23,7 @@ * @uses DOMDocument * @uses DOMXPath * @uses Zend_Rest_Client - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @uses Zend_Service_Yahoo_ImageResultSet * @uses Zend_Service_Yahoo_InlinkDataResultSet * @uses Zend_Service_Yahoo_LocalResultSet @@ -31,7 +31,7 @@ * @uses Zend_Service_Yahoo_PageDataResultSet * @uses Zend_Service_Yahoo_VideoResultSet * @uses Zend_Service_Yahoo_WebResultSet - * @uses Zend_Validate_Between + * @uses Zend\Validator\Between * @category Zend * @package Zend_Service * @subpackage Yahoo @@ -64,7 +64,7 @@ class Zend_Service_Yahoo public function __construct($appId) { $this->appId = (string) $appId; - $this->_rest = new Zend_Rest_Client('http://search.yahooapis.com'); + $this->_rest = new Zend\Rest\Client\RestClient('http://search.yahooapis.com'); } @@ -80,7 +80,7 @@ public function __construct($appId) * @param string $query the query being run * @param array $options any optional parameters * @return Zend_Service_Yahoo_ResultSet The return set - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function inlinkDataSearch($query, array $options = array()) { @@ -95,7 +95,7 @@ public function inlinkDataSearch($query, array $options = array()) $response = $this->_rest->restGet('/SiteExplorerService/V1/inlinkData', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' . + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -124,7 +124,7 @@ public function inlinkDataSearch($query, array $options = array()) * @param string $query the query to be run * @param array $options an optional array of query options * @return Zend_Service_Yahoo_ImageResultSet the search results - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function imageSearch($query, array $options = array()) { @@ -143,7 +143,7 @@ public function imageSearch($query, array $options = array()) $response = $this->_rest->restGet('/ImageSearchService/V1/imageSearch', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' . + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -181,7 +181,7 @@ public function imageSearch($query, array $options = array()) * @param string $query The query string you want to run * @param array $options The search options, including location * @return Zend_Service_Yahoo_LocalResultSet The results - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function localSearch($query, array $options = array()) { @@ -199,7 +199,7 @@ public function localSearch($query, array $options = array()) $response = $this->_rest->restGet('/LocalSearchService/V1/localSearch', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' . + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -228,7 +228,7 @@ public function localSearch($query, array $options = array()) * @param string $query The query to run * @param array $options The array of optional parameters * @return Zend_Service_Yahoo_NewsResultSet The query return set - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function newsSearch($query, array $options = array()) { @@ -245,7 +245,7 @@ public function newsSearch($query, array $options = array()) $response = $this->_rest->restGet('/NewsSearchService/V1/newsSearch', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' . + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -269,7 +269,7 @@ public function newsSearch($query, array $options = array()) * @param string $query the query being run * @param array $options any optional parameters * @return Zend_Service_Yahoo_ResultSet The return set - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function pageDataSearch($query, array $options = array()) { @@ -284,7 +284,7 @@ public function pageDataSearch($query, array $options = array()) $response = $this->_rest->restGet('/SiteExplorerService/V1/pageData', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' . + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -312,7 +312,7 @@ public function pageDataSearch($query, array $options = array()) * @param string $query the query to be run * @param array $options an optional array of query options * @return Zend_Service_Yahoo_VideoResultSet the search results - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function videoSearch($query, array $options = array()) { @@ -330,7 +330,7 @@ public function videoSearch($query, array $options = array()) $response = $this->_rest->restGet('/VideoSearchService/V1/videoSearch', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' . + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -362,7 +362,7 @@ public function videoSearch($query, array $options = array()) * @param string $query the query being run * @param array $options any optional parameters * @return Zend_Service_Yahoo_WebResultSet The return set - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ public function webSearch($query, array $options = array()) { @@ -379,7 +379,7 @@ public function webSearch($query, array $options = array()) $response = $this->_rest->restGet('/WebSearchService/V1/webSearch', $options); if ($response->isError()) { - throw new Zend_Service_Exception('An error occurred sending request. Status code: ' . + throw new Zend\Service\Exception('An error occurred sending request. Status code: ' . $response->getStatus()); } @@ -408,7 +408,7 @@ public function getRestClient() * * @param array $options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateInlinkDataSearch(array $options) { @@ -416,14 +416,14 @@ protected function _validateInlinkDataSearch(array $options) $this->_compareOptions($options, $validOptions); - $between = new Zend_Validate_Between(1, 100, true); + $between = new Zend\Validator\Between(1, 100, true); if (isset($options['results']) && !$between->setMin(1)->setMax(100)->isValid($options['results'])) { - throw new Zend_Service_Exception("Invalid value for option 'results': {$options['results']}"); + throw new Zend\Service\Exception("Invalid value for option 'results': {$options['results']}"); } if (isset($options['start']) && !$between->setMin(1)->setMax(1000)->isValid($options['start'])) { - throw new Zend_Service_Exception("Invalid value for option 'start': {$options['start']}"); + throw new Zend\Service\Exception("Invalid value for option 'start': {$options['start']}"); } if (isset($options['omit_inlinks'])) { @@ -437,7 +437,7 @@ protected function _validateInlinkDataSearch(array $options) * * @param array $options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateImageSearch(array $options) { @@ -452,18 +452,18 @@ protected function _validateImageSearch(array $options) case 'phrase': break; default: - throw new Zend_Service_Exception("Invalid value for option 'type': '{$options['type']}'"); + throw new Zend\Service\Exception("Invalid value for option 'type': '{$options['type']}'"); } } - $between = new Zend_Validate_Between(1, 50, true); + $between = new Zend\Validator\Between(1, 50, true); if (isset($options['results']) && !$between->setMin(1)->setMax(50)->isValid($options['results'])) { - throw new Zend_Service_Exception("Invalid value for option 'results': {$options['results']}"); + throw new Zend\Service\Exception("Invalid value for option 'results': {$options['results']}"); } if (isset($options['start']) && !$between->setMin(1)->setMax(1000)->isValid($options['start'])) { - throw new Zend_Service_Exception("Invalid value for option 'start': {$options['start']}"); + throw new Zend\Service\Exception("Invalid value for option 'start': {$options['start']}"); } if (isset($options['format'])) { @@ -475,7 +475,7 @@ protected function _validateImageSearch(array $options) case 'png': break; default: - throw new Zend_Service_Exception("Invalid value for option 'format': {$options['format']}"); + throw new Zend\Service\Exception("Invalid value for option 'format': {$options['format']}"); } } @@ -486,7 +486,7 @@ protected function _validateImageSearch(array $options) case 'bw': break; default: - throw new Zend_Service_Exception("Invalid value for option 'coloration': " + throw new Zend\Service\Exception("Invalid value for option 'coloration': " . "{$options['coloration']}"); } } @@ -498,7 +498,7 @@ protected function _validateImageSearch(array $options) * * @param array $options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateLocalSearch(array $options) { @@ -507,26 +507,26 @@ protected function _validateLocalSearch(array $options) $this->_compareOptions($options, $validOptions); - $between = new Zend_Validate_Between(1, 20, true); + $between = new Zend\Validator\Between(1, 20, true); if (isset($options['results']) && !$between->setMin(1)->setMax(20)->isValid($options['results'])) { - throw new Zend_Service_Exception("Invalid value for option 'results': {$options['results']}"); + throw new Zend\Service\Exception("Invalid value for option 'results': {$options['results']}"); } if (isset($options['start']) && !$between->setMin(1)->setMax(1000)->isValid($options['start'])) { - throw new Zend_Service_Exception("Invalid value for option 'start': {$options['start']}"); + throw new Zend\Service\Exception("Invalid value for option 'start': {$options['start']}"); } if (isset($options['longitude']) && !$between->setMin(-90)->setMax(90)->isValid($options['longitude'])) { - throw new Zend_Service_Exception("Invalid value for option 'longitude': {$options['longitude']}"); + throw new Zend\Service\Exception("Invalid value for option 'longitude': {$options['longitude']}"); } if (isset($options['latitude']) && !$between->setMin(-180)->setMax(180)->isValid($options['latitude'])) { - throw new Zend_Service_Exception("Invalid value for option 'latitude': {$options['latitude']}"); + throw new Zend\Service\Exception("Invalid value for option 'latitude': {$options['latitude']}"); } if (isset($options['zip']) && !preg_match('/(^\d{5}$)|(^\d{5}-\d{4}$)/', $options['zip'])) { - throw new Zend_Service_Exception("Invalid value for option 'zip': {$options['zip']}"); + throw new Zend\Service\Exception("Invalid value for option 'zip': {$options['zip']}"); } $hasLocation = false; @@ -539,11 +539,11 @@ protected function _validateLocalSearch(array $options) } if (!$hasLocation && (!isset($options['latitude']) || !isset($options['longitude']))) { - throw new Zend_Service_Exception('Location data are required but missing'); + throw new Zend\Service\Exception('Location data are required but missing'); } if (!in_array($options['sort'], array('relevance', 'title', 'distance', 'rating'))) { - throw new Zend_Service_Exception("Invalid value for option 'sort': {$options['sort']}"); + throw new Zend\Service\Exception("Invalid value for option 'sort': {$options['sort']}"); } } @@ -553,7 +553,7 @@ protected function _validateLocalSearch(array $options) * * @param array $options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateNewsSearch(array $options) { @@ -561,14 +561,14 @@ protected function _validateNewsSearch(array $options) $this->_compareOptions($options, $validOptions); - $between = new Zend_Validate_Between(1, 50, true); + $between = new Zend\Validator\Between(1, 50, true); if (isset($options['results']) && !$between->setMin(1)->setMax(50)->isValid($options['results'])) { - throw new Zend_Service_Exception("Invalid value for option 'results': {$options['results']}"); + throw new Zend\Service\Exception("Invalid value for option 'results': {$options['results']}"); } if (isset($options['start']) && !$between->setMin(1)->setMax(1000)->isValid($options['start'])) { - throw new Zend_Service_Exception("Invalid value for option 'start': {$options['start']}"); + throw new Zend\Service\Exception("Invalid value for option 'start': {$options['start']}"); } if (isset($options['language'])) { @@ -585,7 +585,7 @@ protected function _validateNewsSearch(array $options) * * @param array $options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validatePageDataSearch(array $options) { @@ -593,14 +593,14 @@ protected function _validatePageDataSearch(array $options) $this->_compareOptions($options, $validOptions); - $between = new Zend_Validate_Between(1, 100, true); + $between = new Zend\Validator\Between(1, 100, true); if (isset($options['results']) && !$between->setMin(1)->setMax(100)->isValid($options['results'])) { - throw new Zend_Service_Exception("Invalid value for option 'results': {$options['results']}"); + throw new Zend\Service\Exception("Invalid value for option 'results': {$options['results']}"); } if (isset($options['start']) && !$between->setMin(1)->setMax(1000)->isValid($options['start'])) { - throw new Zend_Service_Exception("Invalid value for option 'start': {$options['start']}"); + throw new Zend\Service\Exception("Invalid value for option 'start': {$options['start']}"); } } @@ -610,7 +610,7 @@ protected function _validatePageDataSearch(array $options) * * @param array $options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateVideoSearch(array $options) { @@ -622,14 +622,14 @@ protected function _validateVideoSearch(array $options) $this->_validateInArray('type', $options['type'], array('all', 'any', 'phrase')); } - $between = new Zend_Validate_Between(1, 50, true); + $between = new Zend\Validator\Between(1, 50, true); if (isset($options['results']) && !$between->setMin(1)->setMax(50)->isValid($options['results'])) { - throw new Zend_Service_Exception("Invalid value for option 'results': {$options['results']}"); + throw new Zend\Service\Exception("Invalid value for option 'results': {$options['results']}"); } if (isset($options['start']) && !$between->setMin(1)->setMax(1000)->isValid($options['start'])) { - throw new Zend_Service_Exception("Invalid value for option 'start': {$options['start']}"); + throw new Zend\Service\Exception("Invalid value for option 'start': {$options['start']}"); } if (isset($options['format'])) { @@ -643,7 +643,7 @@ protected function _validateVideoSearch(array $options) * * @param array $options * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateWebSearch(array $options) { @@ -652,14 +652,14 @@ protected function _validateWebSearch(array $options) $this->_compareOptions($options, $validOptions); - $between = new Zend_Validate_Between(1, 100, true); + $between = new Zend\Validator\Between(1, 100, true); if (isset($options['results']) && !$between->setMin(1)->setMax(100)->isValid($options['results'])) { - throw new Zend_Service_Exception("Invalid value for option 'results': {$options['results']}"); + throw new Zend\Service\Exception("Invalid value for option 'results': {$options['results']}"); } if (isset($options['start']) && !$between->setMin(1)->setMax(1000)->isValid($options['start'])) { - throw new Zend_Service_Exception("Invalid value for option 'start': {$options['start']}"); + throw new Zend\Service\Exception("Invalid value for option 'start': {$options['start']}"); } if (isset($options['language'])) { @@ -705,7 +705,7 @@ protected function _prepareOptions($query, array $options, array $defaultOptions * * @param string $lang Language code * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateLanguage($lang) { @@ -714,7 +714,7 @@ protected function _validateLanguage($lang) 'es', 'sv', 'th', 'tr' ); if (!in_array($lang, $languages)) { - throw new Zend_Service_Exception("The selected language '$lang' is not supported"); + throw new Zend\Service\Exception("The selected language '$lang' is not supported"); } } @@ -725,13 +725,13 @@ protected function _validateLanguage($lang) * @param array $options User specified options * @param array $validOptions Valid options * @return void - * @throws Zend_Service_Exception if difference is found (e.g., unsupported query option) + * @throws Zend\Service\Exception if difference is found (e.g., unsupported query option) */ protected function _compareOptions(array $options, array $validOptions) { $difference = array_diff(array_keys($options), $validOptions); if ($difference) { - throw new Zend_Service_Exception('The following parameters are invalid: ' . join(', ', $difference)); + throw new Zend\Service\Exception('The following parameters are invalid: ' . join(', ', $difference)); } } @@ -743,12 +743,12 @@ protected function _compareOptions(array $options, array $validOptions) * @param mixed $value Value * @param array $array Array in which to check for the value * @return void - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception */ protected function _validateInArray($name, $value, array $array) { if (!in_array($value, $array)) { - throw new Zend_Service_Exception("Invalid value for option '$name': $value"); + throw new Zend\Service\Exception("Invalid value for option '$name': $value"); } } @@ -758,7 +758,7 @@ protected function _validateInArray($name, $value, array $array) * * @param DOMDocument $dom DOM Object representing the result XML * @return void - * @throws Zend_Service_Exception Thrown when the result from Yahoo! is an error + * @throws Zend\Service\Exception Thrown when the result from Yahoo! is an error */ protected static function _checkErrors(DOMDocument $dom) { @@ -767,7 +767,7 @@ protected static function _checkErrors(DOMDocument $dom) if ($xpath->query('//yapi:Error')->length >= 1) { $message = $xpath->query('//yapi:Error/yapi:Message/text()')->item(0)->data; - throw new Zend_Service_Exception($message); + throw new Zend\Service\Exception($message); } } } diff --git a/library/Zend/Service/Yahoo/ResultSet.php b/library/Zend/Service/Yahoo/ResultSet.php index dcdc9e27f66..cbee6ea4e44 100644 --- a/library/Zend/Service/Yahoo/ResultSet.php +++ b/library/Zend/Service/Yahoo/ResultSet.php @@ -23,7 +23,7 @@ * @uses DOMXPath * @uses OutOfBoundsException * @uses SeekableIterator - * @uses Zend_Service_Exception + * @uses Zend\Service\Exception * @category Zend * @package Zend_Service * @subpackage Yahoo @@ -119,12 +119,12 @@ public function totalResults() * * Must be implemented by child classes * - * @throws Zend_Service_Exception + * @throws Zend\Service\Exception * @return Zend_Service_Yahoo_Result */ public function current() { - throw new Zend_Service_Exception('Zend_Service_Yahoo_ResultSet::current() must be implemented by child ' + throw new Zend\Service\Exception('Zend_Service_Yahoo_ResultSet::current() must be implemented by child ' . 'classes'); } diff --git a/library/Zend/Validator/Alnum.php b/library/Zend/Validator/Alnum.php index 62cecf62862..88cfad46de4 100644 --- a/library/Zend/Validator/Alnum.php +++ b/library/Zend/Validator/Alnum.php @@ -109,8 +109,6 @@ public function setAllowWhiteSpace($allowWhiteSpace) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value contains only alphabetic and digit characters * * @param string $value diff --git a/library/Zend/Validator/Alpha.php b/library/Zend/Validator/Alpha.php index edda05eb236..9b810ec1e93 100644 --- a/library/Zend/Validator/Alpha.php +++ b/library/Zend/Validator/Alpha.php @@ -109,8 +109,6 @@ public function setAllowWhiteSpace($allowWhiteSpace) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value contains only alphabetic characters * * @param string $value diff --git a/library/Zend/Validator/Between.php b/library/Zend/Validator/Between.php index 9aabe388baf..5e6aa3667d2 100644 --- a/library/Zend/Validator/Between.php +++ b/library/Zend/Validator/Between.php @@ -195,8 +195,6 @@ public function setInclusive($inclusive) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value is between min and max options, inclusively * if inclusive option is true. * diff --git a/library/Zend/Validator/Callback.php b/library/Zend/Validator/Callback.php index e2cae029295..80871a0e6b1 100644 --- a/library/Zend/Validator/Callback.php +++ b/library/Zend/Validator/Callback.php @@ -141,8 +141,6 @@ public function setOptions($options) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the set callback returns * for the provided $value * diff --git a/library/Zend/Validator/Ccnum.php b/library/Zend/Validator/Ccnum.php index 11722fe2e10..55901dc4ef7 100644 --- a/library/Zend/Validator/Ccnum.php +++ b/library/Zend/Validator/Ccnum.php @@ -66,8 +66,6 @@ public function __construct() } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value follows the Luhn algorithm (mod-10 checksum) * * @param string $value diff --git a/library/Zend/Validator/CreditCard.php b/library/Zend/Validator/CreditCard.php index cce359d4000..4d1969be101 100644 --- a/library/Zend/Validator/CreditCard.php +++ b/library/Zend/Validator/CreditCard.php @@ -237,8 +237,6 @@ public function setService($service) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value follows the Luhn algorithm (mod-10 checksum) * * @param string $value diff --git a/library/Zend/Validator/Date.php b/library/Zend/Validator/Date.php index 6323880d0c7..c6fb8d75f41 100644 --- a/library/Zend/Validator/Date.php +++ b/library/Zend/Validator/Date.php @@ -153,8 +153,6 @@ public function setFormat($format = null) } /** - * Defined by Zend_Validate_Interface - * * Returns true if $value is a valid date of the format YYYY-MM-DD * If optional $format or $locale is set the date format is checked * according to Zend_Date, see Zend_Date::isDate() diff --git a/library/Zend/Validator/Db/AbstractDb.php b/library/Zend/Validator/Db/AbstractDb.php index 3f06b8e9f2f..f635609762f 100644 --- a/library/Zend/Validator/Db/AbstractDb.php +++ b/library/Zend/Validator/Db/AbstractDb.php @@ -88,7 +88,7 @@ abstract class AbstractDb extends AbstractValidator protected $_adapter = null; /** - * Provides basic configuration for use with Zend_Validate_Db Validators + * Provides basic configuration for use with Zend\Validator\Db Validators * Setting $exclude allows a single record to be excluded from matching. * Exclude can either be a String containing a where clause, or an array with `field` and `value` keys * to define the where clause added to the sql. diff --git a/library/Zend/Validator/Digits.php b/library/Zend/Validator/Digits.php index c49b0af0a80..5db61132c0d 100644 --- a/library/Zend/Validator/Digits.php +++ b/library/Zend/Validator/Digits.php @@ -56,8 +56,6 @@ class Digits extends AbstractValidator ); /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value only contains digit characters * * @param string $value diff --git a/library/Zend/Validator/EmailAddress.php b/library/Zend/Validator/EmailAddress.php index d7a3995bed2..629d431d52d 100644 --- a/library/Zend/Validator/EmailAddress.php +++ b/library/Zend/Validator/EmailAddress.php @@ -116,8 +116,8 @@ class EmailAddress extends AbstractValidator * Instantiates hostname validator for local use * * The following option keys are supported: - * 'hostname' => A hostname validator, see Zend_Validate_Hostname - * 'allow' => Options for the hostname validator, see Zend_Validate_Hostname::ALLOW_* + * 'hostname' => A hostname validator, see Zend\Validator\Hostname + * 'allow' => Options for the hostname validator, see Zend\Validator\Hostname::ALLOW_* * 'mx' => If MX check should be enabled, boolean * 'deep' => If a deep MX check should be done, boolean * diff --git a/library/Zend/Validator/File/Count.php b/library/Zend/Validator/File/Count.php index 98599c4b201..0bbc6d9e6bb 100644 --- a/library/Zend/Validator/File/Count.php +++ b/library/Zend/Validator/File/Count.php @@ -227,8 +227,6 @@ public function addFile($file) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the file count of all checked files is at least min and * not bigger than max (when max is not null). Attention: When checking with set min you * must give all files with the first call, otherwise you will get an false. diff --git a/library/Zend/Validator/File/Crc32.php b/library/Zend/Validator/File/Crc32.php index e907a818c0d..b9d66d5e60b 100644 --- a/library/Zend/Validator/File/Crc32.php +++ b/library/Zend/Validator/File/Crc32.php @@ -147,8 +147,6 @@ public function addCrc32($options) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the given file confirms the set hash * * @param string $value Filename to check for hash diff --git a/library/Zend/Validator/File/ExcludeExtension.php b/library/Zend/Validator/File/ExcludeExtension.php index 4f6bed7ba5f..8854ada9961 100644 --- a/library/Zend/Validator/File/ExcludeExtension.php +++ b/library/Zend/Validator/File/ExcludeExtension.php @@ -50,8 +50,6 @@ class ExcludeExtension extends Extension ); /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the fileextension of $value is not included in the * set extension list * diff --git a/library/Zend/Validator/File/ExcludeMimeType.php b/library/Zend/Validator/File/ExcludeMimeType.php index ea8b84cdf4f..087556f54d9 100644 --- a/library/Zend/Validator/File/ExcludeMimeType.php +++ b/library/Zend/Validator/File/ExcludeMimeType.php @@ -41,8 +41,6 @@ class ExcludeMimeType extends MimeType const NOT_READABLE = 'fileExcludeMimeTypeNotReadable'; /** - * Defined by Zend_Validate_Interface - * * Returns true if the mimetype of the file does not matche the given ones. Also parts * of mimetypes can be checked. If you give for example "image" all image * mime types will not be accepted like "image/gif", "image/jpeg" and so on. diff --git a/library/Zend/Validator/File/Exists.php b/library/Zend/Validator/File/Exists.php index 228e50e0399..b7c5b282177 100644 --- a/library/Zend/Validator/File/Exists.php +++ b/library/Zend/Validator/File/Exists.php @@ -149,8 +149,6 @@ public function addDirectory($directory) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the file already exists in the set directories * * @param string $value Real file to check for existance diff --git a/library/Zend/Validator/File/Extension.php b/library/Zend/Validator/File/Extension.php index 339c93af529..123c014ff41 100644 --- a/library/Zend/Validator/File/Extension.php +++ b/library/Zend/Validator/File/Extension.php @@ -176,8 +176,6 @@ public function addExtension($extension) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the fileextension of $value is included in the * set extension list * diff --git a/library/Zend/Validator/File/FilesSize.php b/library/Zend/Validator/File/FilesSize.php index 24e6018abb1..219ecaaff3b 100644 --- a/library/Zend/Validator/File/FilesSize.php +++ b/library/Zend/Validator/File/FilesSize.php @@ -94,8 +94,6 @@ public function __construct($options) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the disk usage of all files is at least min and * not bigger than max (when max is not null). * diff --git a/library/Zend/Validator/File/Hash.php b/library/Zend/Validator/File/Hash.php index c882281287b..6d9cb4dfc9e 100644 --- a/library/Zend/Validator/File/Hash.php +++ b/library/Zend/Validator/File/Hash.php @@ -142,8 +142,6 @@ public function addHash($options) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the given file confirms the set hash * * @param string $value Filename to check for hash diff --git a/library/Zend/Validator/File/ImageSize.php b/library/Zend/Validator/File/ImageSize.php index fbb6fe2335e..c9f9f2dbb9b 100644 --- a/library/Zend/Validator/File/ImageSize.php +++ b/library/Zend/Validator/File/ImageSize.php @@ -295,8 +295,6 @@ public function setImageHeight($options) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the imagesize of $value is at least min and * not bigger than max * diff --git a/library/Zend/Validator/File/Md5.php b/library/Zend/Validator/File/Md5.php index 1855dd59365..a5c9903b2fe 100644 --- a/library/Zend/Validator/File/Md5.php +++ b/library/Zend/Validator/File/Md5.php @@ -151,8 +151,6 @@ public function addMd5($options) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the given file confirms the set hash * * @param string $value Filename to check for hash diff --git a/library/Zend/Validator/File/NotExists.php b/library/Zend/Validator/File/NotExists.php index 3309ae9294d..1a18dd88f5e 100644 --- a/library/Zend/Validator/File/NotExists.php +++ b/library/Zend/Validator/File/NotExists.php @@ -47,8 +47,6 @@ class NotExists extends Exists ); /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the file does not exist in the set destinations * * @param string $value Real file to check for diff --git a/library/Zend/Validator/File/Sha1.php b/library/Zend/Validator/File/Sha1.php index c7706a30945..c67aecfd0f2 100644 --- a/library/Zend/Validator/File/Sha1.php +++ b/library/Zend/Validator/File/Sha1.php @@ -149,8 +149,6 @@ public function addSha1($options) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the given file confirms the set hash * * @param string $value Filename to check for hash diff --git a/library/Zend/Validator/File/Size.php b/library/Zend/Validator/File/Size.php index 81c406f0693..64774f80f30 100644 --- a/library/Zend/Validator/File/Size.php +++ b/library/Zend/Validator/File/Size.php @@ -261,8 +261,6 @@ protected function _setSize($size) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the filesize of $value is at least min and * not bigger than max (when max is not null). * diff --git a/library/Zend/Validator/File/Upload.php b/library/Zend/Validator/File/Upload.php index 48b0afcd275..d0521681e44 100644 --- a/library/Zend/Validator/File/Upload.php +++ b/library/Zend/Validator/File/Upload.php @@ -146,8 +146,6 @@ public function setFiles($files = array()) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the file was uploaded without errors * * @param string $value Single file to check for upload errors, when giving null the $_FILES array diff --git a/library/Zend/Validator/File/WordCount.php b/library/Zend/Validator/File/WordCount.php index 417175da5dd..684b6135c5a 100644 --- a/library/Zend/Validator/File/WordCount.php +++ b/library/Zend/Validator/File/WordCount.php @@ -53,8 +53,6 @@ class WordCount extends Count ); /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the counted words are at least min and * not bigger than max (when max is not null). * diff --git a/library/Zend/Validator/Float.php b/library/Zend/Validator/Float.php index 67659413380..4f6c0722b4b 100644 --- a/library/Zend/Validator/Float.php +++ b/library/Zend/Validator/Float.php @@ -98,8 +98,6 @@ public function setLocale($locale = null) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value is a floating-point value * * @param string $value diff --git a/library/Zend/Validator/GreaterThan.php b/library/Zend/Validator/GreaterThan.php index 600024ad021..b2bf963f010 100644 --- a/library/Zend/Validator/GreaterThan.php +++ b/library/Zend/Validator/GreaterThan.php @@ -103,8 +103,6 @@ public function setMin($min) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value is greater than min option * * @param mixed $value diff --git a/library/Zend/Validator/Hex.php b/library/Zend/Validator/Hex.php index f532f252051..dabede39cc6 100644 --- a/library/Zend/Validator/Hex.php +++ b/library/Zend/Validator/Hex.php @@ -46,8 +46,6 @@ class Hex extends AbstractValidator ); /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value contains only hexadecimal digit characters * * @param string $value diff --git a/library/Zend/Validator/Hostname.php b/library/Zend/Validator/Hostname.php index 46af5dee079..e429f092522 100644 --- a/library/Zend/Validator/Hostname.php +++ b/library/Zend/Validator/Hostname.php @@ -474,8 +474,6 @@ public function setValidateTld ($allowed) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the $value is a valid hostname with respect to the current allow option * * @param string $value diff --git a/library/Zend/Validator/Iban.php b/library/Zend/Validator/Iban.php index 37cca01f00d..37314b0fc8e 100644 --- a/library/Zend/Validator/Iban.php +++ b/library/Zend/Validator/Iban.php @@ -169,8 +169,6 @@ public function setLocale($locale = null) } /** - * Defined by Zend_Validate_Interface - * * Returns true if $value is a valid IBAN * * @param string $value diff --git a/library/Zend/Validator/Identical.php b/library/Zend/Validator/Identical.php index 065b1162594..8979740addd 100644 --- a/library/Zend/Validator/Identical.php +++ b/library/Zend/Validator/Identical.php @@ -122,7 +122,7 @@ public function getStrict() /** * Sets the strict parameter * - * @param Zend_Validate_Identical + * @param Zend\Validator\Identical */ public function setStrict($strict) { @@ -131,8 +131,6 @@ public function setStrict($strict) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if a token has been set and the provided value * matches that token. * diff --git a/library/Zend/Validator/InArray.php b/library/Zend/Validator/InArray.php index a30cae4c2ab..382fb299738 100644 --- a/library/Zend/Validator/InArray.php +++ b/library/Zend/Validator/InArray.php @@ -172,8 +172,6 @@ public function setRecursive($recursive) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value is contained in the haystack option. If the strict * option is true, then the type of $value is also checked. * diff --git a/library/Zend/Validator/Int.php b/library/Zend/Validator/Int.php index 66ebabb5e80..503fa496d84 100644 --- a/library/Zend/Validator/Int.php +++ b/library/Zend/Validator/Int.php @@ -99,8 +99,6 @@ public function setLocale($locale = null) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value is a valid integer * * @param string|integer $value diff --git a/library/Zend/Validator/Ip.php b/library/Zend/Validator/Ip.php index 910869bd16f..30d1bfcdde8 100644 --- a/library/Zend/Validator/Ip.php +++ b/library/Zend/Validator/Ip.php @@ -112,8 +112,6 @@ public function setOptions($options) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value is a valid IP address * * @param mixed $value diff --git a/library/Zend/Validator/Isbn.php b/library/Zend/Validator/Isbn.php index c7ee1f58149..89d3a71221c 100644 --- a/library/Zend/Validator/Isbn.php +++ b/library/Zend/Validator/Isbn.php @@ -142,8 +142,6 @@ protected function _detectFormat() } /** - * Defined by Zend_Validate_Interface. - * * Returns true if and only if $value is a valid ISBN. * * @param string $value diff --git a/library/Zend/Validator/LessThan.php b/library/Zend/Validator/LessThan.php index d23087ee23e..fdbc059b6a7 100644 --- a/library/Zend/Validator/LessThan.php +++ b/library/Zend/Validator/LessThan.php @@ -102,8 +102,6 @@ public function setMax($max) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value is less than max option * * @param mixed $value diff --git a/library/Zend/Validator/NotEmpty.php b/library/Zend/Validator/NotEmpty.php index ea44b4fb9b6..7bacbd1ab6c 100644 --- a/library/Zend/Validator/NotEmpty.php +++ b/library/Zend/Validator/NotEmpty.php @@ -148,8 +148,6 @@ public function setType($type = null) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value is not an empty value. * * @param string $value diff --git a/library/Zend/Validator/PostCode.php b/library/Zend/Validator/PostCode.php index 81677e91bc8..6c25fc3d539 100644 --- a/library/Zend/Validator/PostCode.php +++ b/library/Zend/Validator/PostCode.php @@ -179,8 +179,6 @@ public function setFormat($format) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value is a valid postalcode * * @param string $value diff --git a/library/Zend/Validator/Regex.php b/library/Zend/Validator/Regex.php index 0efd29f2534..1362d542abc 100644 --- a/library/Zend/Validator/Regex.php +++ b/library/Zend/Validator/Regex.php @@ -114,8 +114,6 @@ public function setPattern($pattern) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if $value matches against the pattern option * * @param string $value diff --git a/library/Zend/Validator/StringLength.php b/library/Zend/Validator/StringLength.php index c9aa605e922..70b1596b017 100644 --- a/library/Zend/Validator/StringLength.php +++ b/library/Zend/Validator/StringLength.php @@ -206,8 +206,6 @@ public function setEncoding($encoding = null) } /** - * Defined by Zend_Validate_Interface - * * Returns true if and only if the string length of $value is at least the min option and * no greater than the max option (when the max option is not null). * diff --git a/library/Zend/Validator/ValidatorChain.php b/library/Zend/Validator/ValidatorChain.php index fbcbbeb033e..d3e53faafe7 100644 --- a/library/Zend/Validator/ValidatorChain.php +++ b/library/Zend/Validator/ValidatorChain.php @@ -106,8 +106,6 @@ public function isValid($value) } /** - * Defined by Zend_Validate_Interface - * * Returns array of validation failure messages * * @return array @@ -118,8 +116,6 @@ public function getMessages() } /** - * Defined by Zend_Validate_Interface - * * Returns array of validation failure message codes * * @return array diff --git a/library/Zend/View/Helper/Navigation/Sitemap.php b/library/Zend/View/Helper/Navigation/Sitemap.php index 7d9a1b3215d..f5f5abc0ef4 100644 --- a/library/Zend/View/Helper/Navigation/Sitemap.php +++ b/library/Zend/View/Helper/Navigation/Sitemap.php @@ -170,7 +170,7 @@ public function getUseXmlDeclaration() } /** - * Sets whether sitemap should be validated using Zend_Validate_Sitemap_* + * Sets whether sitemap should be validated using Zend\Validate\Sitemap_* * * @param bool $useSitemapValidators whether sitemap validators * should be used @@ -184,7 +184,7 @@ public function setUseSitemapValidators($useSitemapValidators) } /** - * Returns whether sitemap should be validated using Zend_Validate_Sitemap_* + * Returns whether sitemap should be validated using Zend\Validate\Sitemap_* * * @return bool whether sitemap should be validated using validators */ diff --git a/tests/Zend/Amf/AuthTest.php b/tests/Zend/Amf/AuthTest.php index 3c7571d19fe..5596fa8e8d5 100644 --- a/tests/Zend/Amf/AuthTest.php +++ b/tests/Zend/Amf/AuthTest.php @@ -49,12 +49,6 @@ class AuthTest extends \PHPUnit_Framework_TestCase */ protected $_server; - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Amf_AuthTest"); - \PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { $this->_server = new Amf\Server(); diff --git a/tests/Zend/Amf/TestAsset/IntrospectorTest.php b/tests/Zend/Amf/TestAsset/IntrospectorTest.php index 3b9f8ef54a0..e8df9a9be1d 100644 --- a/tests/Zend/Amf/TestAsset/IntrospectorTest.php +++ b/tests/Zend/Amf/TestAsset/IntrospectorTest.php @@ -1,7 +1,34 @@ body = new \Zend\Amf\Value\MessageBody('/foo', '/bar', 'data'); diff --git a/tests/Zend/Amf/Value/MessageHeaderTest.php b/tests/Zend/Amf/Value/MessageHeaderTest.php index a9937c9bc9e..c9e4656c084 100644 --- a/tests/Zend/Amf/Value/MessageHeaderTest.php +++ b/tests/Zend/Amf/Value/MessageHeaderTest.php @@ -25,11 +25,6 @@ namespace ZendTest\Amf\Value; use Zend\Amf\Value; -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Amf_Value_MessageHeaderTest::main'); -} - - /** * Test case for Zend_Amf_Value_MessageHeader * @@ -42,17 +37,6 @@ */ class MessageHeaderTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Amf_Value_MessageHeaderTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - public function testConstructorShouldSetMessageHeaderName() { $messageHeader = new Value\MessageHeader('foo', true, 'content'); @@ -96,7 +80,3 @@ public function testConstructorShouldCastLengthToInteger() $this->assertSame(2, $messageHeader->length); } } - -if (PHPUnit_MAIN_METHOD == 'Zend_Amf_Value_MessageHeaderTest::main') { - \Zend_Amf_Value_MessageHeaderTest::main(); -} diff --git a/tests/Zend/Application/TestAsset/appconfig.inc b/tests/Zend/Application/TestAsset/appconfig.inc index b27cb7657b1..b2c74387d6d 100644 --- a/tests/Zend/Application/TestAsset/appconfig.inc +++ b/tests/Zend/Application/TestAsset/appconfig.inc @@ -1,7 +1,4 @@ 'bar', ); diff --git a/tests/Zend/Barcode/Object/TestAsset/BarcodeTest.php b/tests/Zend/Barcode/Object/TestAsset/BarcodeTest.php index 4ab62c71c5d..65515344dc8 100644 --- a/tests/Zend/Barcode/Object/TestAsset/BarcodeTest.php +++ b/tests/Zend/Barcode/Object/TestAsset/BarcodeTest.php @@ -1,6 +1,34 @@ markTestSkipped('File Zend/Log.php already included'); } + if (!class_exists('Zend_Cache_Core', true)) { + $this->markTestIncomplete('File Zend/Cache/Core.php cannot be found'); + } + $cacheCore = new Zend_Cache_Core( array('logging' => true) ); diff --git a/tests/Zend/Cache/ManagerTest.php b/tests/Zend/Cache/ManagerTest.php index 45dc37048b7..5832f36c5ce 100644 --- a/tests/Zend/Cache/ManagerTest.php +++ b/tests/Zend/Cache/ManagerTest.php @@ -12,8 +12,9 @@ * obtain it through the world-wide-web, please send an email * to license@zend.com so we can send you a copy immediately. * - * @category Zend_Cache - * @package UnitTests + * @category Zend + * @package Zend_Cache + * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -22,8 +23,10 @@ use Zend\Cache; /** - * @category Zend_Cache - * @package UnitTests + * @category Zend + * @package Zend_Cache + * @subpackage UnitTests + * @group Zend_Cache * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Cache/SkipTests.php b/tests/Zend/Cache/SkipTests.php index cf0339c38a2..90769b600f0 100644 --- a/tests/Zend/Cache/SkipTests.php +++ b/tests/Zend/Cache/SkipTests.php @@ -19,13 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * PHPUnit_Framework_TestCase - */ - - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Cache diff --git a/tests/Zend/Cache/StaticBackendTest.php b/tests/Zend/Cache/StaticBackendTest.php index ca2d1970a02..57dcfd6c02b 100644 --- a/tests/Zend/Cache/StaticBackendTest.php +++ b/tests/Zend/Cache/StaticBackendTest.php @@ -1,15 +1,34 @@ assertEquals('value2', $this->request->getParam('param2')); } } - -// Call Zend_Controller_Plugin_PutHandlerTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Controller_Plugin_PutHandlerTest::main") { - \Zend_Controller_Plugin_PutHandlerTest::main(); -} - diff --git a/tests/Zend/Controller/Request/Apache404Test.php b/tests/Zend/Controller/Request/Apache404Test.php index 0925409a7d5..96b0f320f70 100644 --- a/tests/Zend/Controller/Request/Apache404Test.php +++ b/tests/Zend/Controller/Request/Apache404Test.php @@ -25,13 +25,6 @@ namespace ZendTest\Controller\Request; use Zend\Controller\Request; -// Call Zend_Controller_Request_Apache404Test::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Controller_Request_Apache404Test::main"); -} - - - /** * Test class for Zend_Controller_Request_Apache404. * Generated by PHPUnit_Util_Skeleton on 2007-06-25 at 08:20:40. @@ -52,19 +45,6 @@ class Apache404Test extends \PHPUnit_Framework_TestCase */ protected $_server; - /** - * Runs the test methods of this class. - * - * @access public - * @static - */ - public static function main() - { - - $suite = new \PHPUnit_Framework_TestSuite("Zend_Controller_Request_Apache404Test"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { $this->_server = $_SERVER; @@ -101,7 +81,3 @@ public function testRedirectQueryStringShouldBeParsedIntoGetVars() } } -// Call Zend_Controller_Request_Apache404Test::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Controller_Request_Apache404Test::main") { - \Zend_Controller_Request_Apache404Test::main(); -} diff --git a/tests/Zend/Controller/Request/HttpTestCaseTest.php b/tests/Zend/Controller/Request/HttpTestCaseTest.php index 83457045415..56404d0fd0c 100644 --- a/tests/Zend/Controller/Request/HttpTestCaseTest.php +++ b/tests/Zend/Controller/Request/HttpTestCaseTest.php @@ -24,12 +24,6 @@ */ namespace ZendTest\Controller\Request; -// Call Zend_Controller_Request_HTTPTestCaseTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Controller_Request_HTTPTestCaseTest::main"); -} - - /** Zend_Controller_Request_HTTPTestCase */ /** @@ -45,17 +39,6 @@ */ class HTTPTestCaseTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Controller_Request_HTTPTestCaseTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Sets up the fixture, for example, open a network connection. * This method is called before a test is executed. @@ -314,7 +297,3 @@ public function testShouldAllowSpecifyingRequestMethod() } } -// Call Zend_Controller_Request_HTTPTestCaseTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Controller_Request_HTTPTestCaseTest::main") { - \Zend_Controller_Request_HTTPTestCaseTest::main(); -} diff --git a/tests/Zend/Controller/Request/SimpleTest.php b/tests/Zend/Controller/Request/SimpleTest.php index 5bf97d668b0..7f23135a03d 100644 --- a/tests/Zend/Controller/Request/SimpleTest.php +++ b/tests/Zend/Controller/Request/SimpleTest.php @@ -25,13 +25,6 @@ namespace ZendTest\Controller\Request; use Zend\Controller\Request; -// Call Zend_Controller_Request_SimpleTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Controller_Request_SimpleTest::main"); -} - - - /** * Test class for Zend_Controller_Request_Simple. * @@ -45,19 +38,6 @@ */ class SimpleTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @access public - * @static - */ - public static function main() - { - - $suite = new \PHPUnit_Framework_TestSuite("Zend_Controller_Request_SimpleTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - public function testSimpleRequestIsOfAbstractRequestType() { $request = new Request\Simple(); @@ -74,8 +54,3 @@ public function testSimpleReqestRetainsValuesPassedFromConstructor() } } - -// Call Zend_Controller_Request_SimpleTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Controller_Request_SimpleTest::main") { - \Zend_Controller_Request_SimpleTest::main(); -} diff --git a/tests/Zend/Controller/Response/HttpTestCaseTest.php b/tests/Zend/Controller/Response/HttpTestCaseTest.php index 9526aebee50..b3bd19a3a00 100644 --- a/tests/Zend/Controller/Response/HttpTestCaseTest.php +++ b/tests/Zend/Controller/Response/HttpTestCaseTest.php @@ -24,12 +24,6 @@ */ namespace ZendTest\Controller\Response; -// Call Zend_Controller_Response_HTTPTestCaseTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Controller_Response_HTTPTestCaseTest::main"); -} - - /** Zend_Controller_Response_HTTPTestCase */ /** @@ -45,17 +39,6 @@ */ class HTTPTestCaseTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Controller_Response_HTTPTestCaseTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Sets up the fixture, for example, open a network connection. * This method is called before a test is executed. @@ -129,7 +112,3 @@ public function testCanSendHeadersShouldAlwaysReturnTrue() } } -// Call Zend_Controller_Response_HTTPTestCaseTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Controller_Response_HTTPTestCaseTest::main") { - \Zend_Controller_Response_HTTPTestCaseTest::main(); -} diff --git a/tests/Zend/Controller/_files/modules/bar/views/scripts/index/test.phtml b/tests/Zend/Controller/_files/modules/bar/views/scripts/index/test.phtml index 71012a587d6..10d6014ec78 100644 --- a/tests/Zend/Controller/_files/modules/bar/views/scripts/index/test.phtml +++ b/tests/Zend/Controller/_files/modules/bar/views/scripts/index/test.phtml @@ -1,5 +1,3 @@ Rendered index/test.phtml in bar module diff --git a/tests/Zend/Controller/_files/modules/bar/views/scripts/test.phtml b/tests/Zend/Controller/_files/modules/bar/views/scripts/test.phtml index 82c38f02b8d..b37bc9f4116 100644 --- a/tests/Zend/Controller/_files/modules/bar/views/scripts/test.phtml +++ b/tests/Zend/Controller/_files/modules/bar/views/scripts/test.phtml @@ -1,5 +1,3 @@ Rendered test.phtml in bar module diff --git a/tests/Zend/Controller/views/scripts/foo-bar/baz-bat.phtml b/tests/Zend/Controller/views/scripts/foo-bar/baz-bat.phtml index 6907023176d..6725b3f598f 100644 --- a/tests/Zend/Controller/views/scripts/foo-bar/baz-bat.phtml +++ b/tests/Zend/Controller/views/scripts/foo-bar/baz-bat.phtml @@ -1,5 +1,3 @@ Inside foo-bar/baz-bat.phtml diff --git a/tests/Zend/Controller/views/scripts/site.phtml b/tests/Zend/Controller/views/scripts/site.phtml index 30857c6348f..7866d850e23 100644 --- a/tests/Zend/Controller/views/scripts/site.phtml +++ b/tests/Zend/Controller/views/scripts/site.phtml @@ -1,5 +1,3 @@ In the sitewide view diff --git a/tests/Zend/Controller/views/scripts/view/index.phtml b/tests/Zend/Controller/views/scripts/view/index.phtml index cd766b89c40..317adfe282c 100644 --- a/tests/Zend/Controller/views/scripts/view/index.phtml +++ b/tests/Zend/Controller/views/scripts/view/index.phtml @@ -1,5 +1,3 @@ In the index action view diff --git a/tests/Zend/Controller/views/scripts/view/name.phtml b/tests/Zend/Controller/views/scripts/view/name.phtml index 215f4f5a2b0..380c0a9990b 100644 --- a/tests/Zend/Controller/views/scripts/view/name.phtml +++ b/tests/Zend/Controller/views/scripts/view/name.phtml @@ -1,5 +1,3 @@ In the name view diff --git a/tests/Zend/Db/Adapter/AbstractPdoTest.php b/tests/Zend/Db/Adapter/AbstractPdoTest.php index 032649eb8f3..78dc3347685 100644 --- a/tests/Zend/Db/Adapter/AbstractPdoTest.php +++ b/tests/Zend/Db/Adapter/AbstractPdoTest.php @@ -19,17 +19,15 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * @namespace - */ namespace ZendTest\Db\Adapter; use Zend\Db\Adapter; - /** * @category Zend * @package Zend_Db * @subpackage UnitTests + * @group Zend_Db + * @group Zend_Db_Adapter * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Db/Adapter/AbstractTest.php b/tests/Zend/Db/Adapter/AbstractTest.php index 275e5c98337..22a048ce798 100644 --- a/tests/Zend/Db/Adapter/AbstractTest.php +++ b/tests/Zend/Db/Adapter/AbstractTest.php @@ -19,18 +19,15 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * @namespace - */ namespace ZendTest\Db\Adapter; use Zend\Config; use Zend\Db; - /** * @category Zend * @package Zend_Db * @subpackage UnitTests + * @group Zend_Db * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Db/Adapter/SqlsrvTest.php b/tests/Zend/Db/Adapter/SqlsrvTest.php index adfbfd7ba24..b79bcbeed4f 100644 --- a/tests/Zend/Db/Adapter/SqlsrvTest.php +++ b/tests/Zend/Db/Adapter/SqlsrvTest.php @@ -19,17 +19,15 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * @namespace - */ namespace ZendTest\Db\Adapter; use Zend\Db; - /** * @category Zend * @package Zend_Db * @subpackage UnitTests + * @group Zend_Db + * @group Zend_Db_Adapter * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Db/Adapter/TestAsset/Test/Db2Statement.php b/tests/Zend/Db/Adapter/TestAsset/Test/Db2Statement.php index fa7fe198c8a..4b87ea9600c 100644 --- a/tests/Zend/Db/Adapter/TestAsset/Test/Db2Statement.php +++ b/tests/Zend/Db/Adapter/TestAsset/Test/Db2Statement.php @@ -24,18 +24,6 @@ */ namespace ZendTest\Db\Adapter\_files\Test; -/** - * PHPUnit_Util_Filter - */ - - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - - -/** - * @see Zend_Db_Statement_Db2 - */ - /** * Test Class for extending base Zend_Db_Statements * diff --git a/tests/Zend/Db/Adapter/TestAsset/Test/MysqliStatement.php b/tests/Zend/Db/Adapter/TestAsset/Test/MysqliStatement.php index 0a79a658f7c..3729b4bf166 100644 --- a/tests/Zend/Db/Adapter/TestAsset/Test/MysqliStatement.php +++ b/tests/Zend/Db/Adapter/TestAsset/Test/MysqliStatement.php @@ -24,18 +24,6 @@ */ namespace ZendTest\Db\Adapter\_files\Test; -/** - * PHPUnit_Util_Filter - */ - - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - - -/** - * @see Zend_Db_Statement_Mysqli - */ - /** * Test Class for extending base Zend_Db_Statements * diff --git a/tests/Zend/Db/Adapter/TestAsset/Test/OracleStatement.php b/tests/Zend/Db/Adapter/TestAsset/Test/OracleStatement.php index b7eea3383ca..19eedf40113 100644 --- a/tests/Zend/Db/Adapter/TestAsset/Test/OracleStatement.php +++ b/tests/Zend/Db/Adapter/TestAsset/Test/OracleStatement.php @@ -24,18 +24,6 @@ */ namespace ZendTest\Db\Adapter\_files\Test; -/** - * PHPUnit_Util_Filter - */ - - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - - -/** - * @see Zend_Db_Statement_Oracle - */ - /** * Test Class for extending base Zend_Db_Statements * diff --git a/tests/Zend/Db/Profiler/FirebugTest.php b/tests/Zend/Db/Profiler/FirebugTest.php index 34ad2684530..32cc5d1359d 100644 --- a/tests/Zend/Db/Profiler/FirebugTest.php +++ b/tests/Zend/Db/Profiler/FirebugTest.php @@ -67,7 +67,7 @@ public function setUp() $this->_db = \Zend\Db\DB::factory('Pdo\Sqlite', array('dbname' => ':memory:', 'profiler' => $this->_profiler)); - $this->_db->getConnection()->exec('CREATE TABLE foo ( + $this->_db->getConnection()->exec('CREATE TEMP TABLE foo ( id INTEGNER NOT NULL, col1 VARCHAR(10) NOT NULL )'); @@ -75,12 +75,8 @@ public function setUp() public function tearDown() { - if (extension_loaded('pdo_sqlite')) { - $this->_db->getConnection()->exec('DROP TABLE foo'); - } - Channel\HttpHeaders::destroyInstance(); - FirePhp\FirePhp::destroyInstance(); + FirePhp::destroyInstance(); } public function testEnable() diff --git a/tests/Zend/Db/Select/AbstractTest.php b/tests/Zend/Db/Select/AbstractTest.php index 56c727f95ce..7000303834a 100644 --- a/tests/Zend/Db/Select/AbstractTest.php +++ b/tests/Zend/Db/Select/AbstractTest.php @@ -19,9 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * @namespace - */ namespace ZendTest\Db\Select; use Zend\DB; use Zend\Db\Select; @@ -30,6 +27,7 @@ * @category Zend * @package Zend_Db * @subpackage UnitTests + * @group Zend_Db * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Db/Table/Rowset/StaticTest.php b/tests/Zend/Db/Table/Rowset/StaticTest.php index b4ec9457c95..c50c3cdf4f5 100644 --- a/tests/Zend/Db/Table/Rowset/StaticTest.php +++ b/tests/Zend/Db/Table/Rowset/StaticTest.php @@ -24,8 +24,6 @@ */ namespace ZendTest\Db\Table\Rowset; -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/Db/Table/Select/AbstractTest.php b/tests/Zend/Db/Table/Select/AbstractTest.php index 53a505f08bc..ca66393e5bb 100644 --- a/tests/Zend/Db/Table/Select/AbstractTest.php +++ b/tests/Zend/Db/Table/Select/AbstractTest.php @@ -19,9 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * @namespace - */ namespace ZendTest\Db\Table\Select; use Zend\Db\Table\Select; @@ -29,6 +26,8 @@ * @category Zend * @package Zend_Db * @subpackage UnitTests + * @group Zend_Db + * @group Zend_Db_Select * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Db/Table/Table/AbstractTest.php b/tests/Zend/Db/Table/Table/AbstractTest.php index 6a2c9633e59..4d5e2c46b39 100644 --- a/tests/Zend/Db/Table/Table/AbstractTest.php +++ b/tests/Zend/Db/Table/Table/AbstractTest.php @@ -19,18 +19,16 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * @namespace - */ namespace ZendTest\Db\Table\Table; use Zend\Db\Table; use Zend\Cache; - /** * @category Zend * @package Zend_Db * @subpackage UnitTests + * @group Zend_Db + * @group Zend_Db_Table * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Db/TestUtil/Common.php b/tests/Zend/Db/TestUtil/Common.php index 9818787011c..749fb40d1e1 100644 --- a/tests/Zend/Db/TestUtil/Common.php +++ b/tests/Zend/Db/TestUtil/Common.php @@ -26,18 +26,6 @@ use Zend\DB; use Zend\Db\Adapter; -/** - * @see Zend_Db_Expr - */ - -/** - * PHPUnit_Util_Filter - */ - - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/Db/TestUtil/Db2.php b/tests/Zend/Db/TestUtil/Db2.php index 7d0402a0415..7f3003bc4ce 100644 --- a/tests/Zend/Db/TestUtil/Db2.php +++ b/tests/Zend/Db/TestUtil/Db2.php @@ -25,8 +25,6 @@ namespace ZendTest\Db\TestUtil; use Zend\DB; -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/Db/TestUtil/Oracle.php b/tests/Zend/Db/TestUtil/Oracle.php index 5d9e61311c8..ff46444c1be 100644 --- a/tests/Zend/Db/TestUtil/Oracle.php +++ b/tests/Zend/Db/TestUtil/Oracle.php @@ -25,13 +25,6 @@ namespace ZendTest\Db\TestUtil; use Zend\DB; -/** - * @see Zend_Db_TestUtil_Pdo_Oci - * @see Zend_Db_TestUtil_Common - */ - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/Db/TestUtil/Pdo/Common.php b/tests/Zend/Db/TestUtil/Pdo/Common.php index 25f997b0b7b..a0d6b9f88d5 100644 --- a/tests/Zend/Db/TestUtil/Pdo/Common.php +++ b/tests/Zend/Db/TestUtil/Pdo/Common.php @@ -24,14 +24,6 @@ */ namespace ZendTest\Db\TestUtil\Pdo; -/** - * @see Zend_Db_TestUtil_Common - */ - - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/Db/TestUtil/Pdo/Ibm.php b/tests/Zend/Db/TestUtil/Pdo/Ibm.php index cd41a90de67..c38c0d08ddb 100644 --- a/tests/Zend/Db/TestUtil/Pdo/Ibm.php +++ b/tests/Zend/Db/TestUtil/Pdo/Ibm.php @@ -24,12 +24,6 @@ */ namespace ZendTest\Db\TestUtil\Pdo; -/** - * @see Zend_Db_TestUtil_Db2 - */ - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/Db/TestUtil/Pdo/Mssql.php b/tests/Zend/Db/TestUtil/Pdo/Mssql.php index 50105f2420d..aa8ce52b4ab 100644 --- a/tests/Zend/Db/TestUtil/Pdo/Mssql.php +++ b/tests/Zend/Db/TestUtil/Pdo/Mssql.php @@ -25,12 +25,6 @@ namespace ZendTest\Db\TestUtil\Pdo; use Zend\DB; -/** - * @see Zend_Db_TestUtil_Pdo_Common - */ - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/Db/TestUtil/Pdo/Oci.php b/tests/Zend/Db/TestUtil/Pdo/Oci.php index 7fbf0ed0f74..982ad416811 100644 --- a/tests/Zend/Db/TestUtil/Pdo/Oci.php +++ b/tests/Zend/Db/TestUtil/Pdo/Oci.php @@ -25,12 +25,6 @@ namespace ZendTest\Db\TestUtil\Pdo; use Zend\DB; -/** - * @see Zend_Db_TestUtil_Pdo_Common - */ - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/Db/TestUtil/Pdo/Pgsql.php b/tests/Zend/Db/TestUtil/Pdo/Pgsql.php index cfa1ad690c8..c9069b4def3 100644 --- a/tests/Zend/Db/TestUtil/Pdo/Pgsql.php +++ b/tests/Zend/Db/TestUtil/Pdo/Pgsql.php @@ -24,12 +24,6 @@ */ namespace ZendTest\Db\TestUtil\Pdo; -/** - * @see Zend_Db_TestUtil_Pdo_Common - */ - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/Db/TestUtil/Pdo/Sqlite.php b/tests/Zend/Db/TestUtil/Pdo/Sqlite.php index 74cee67eb8e..9f90b59e508 100644 --- a/tests/Zend/Db/TestUtil/Pdo/Sqlite.php +++ b/tests/Zend/Db/TestUtil/Pdo/Sqlite.php @@ -24,12 +24,6 @@ */ namespace ZendTest\Db\TestUtil\Pdo; -/** - * @see Zend_Db_TestUtil_Pdo_Common - */ - -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Db diff --git a/tests/Zend/File/Transfer/Adapter/AbstractTest.php b/tests/Zend/File/Transfer/Adapter/AbstractTest.php index 96d3cf9f434..36954352716 100644 --- a/tests/Zend/File/Transfer/Adapter/AbstractTest.php +++ b/tests/Zend/File/Transfer/Adapter/AbstractTest.php @@ -42,17 +42,6 @@ */ class AbstractTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_File_Transfer_Adapter_AbstractTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Sets up the fixture, for example, open a network connection. * This method is called before a test is executed. diff --git a/tests/Zend/Form/TestAsset/decorators/Label.php b/tests/Zend/Form/TestAsset/decorators/Label.php index 711be5f2bcf..0235661df61 100644 --- a/tests/Zend/Form/TestAsset/decorators/Label.php +++ b/tests/Zend/Form/TestAsset/decorators/Label.php @@ -23,9 +23,6 @@ use Zend\Form\Decorator\AbstractDecorator; -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - - /** * Mock file for testbed * diff --git a/tests/Zend/Form/TestAsset/decorators/TableRow.php b/tests/Zend/Form/TestAsset/decorators/TableRow.php index ff9762e5e29..52c2d8db0a6 100644 --- a/tests/Zend/Form/TestAsset/decorators/TableRow.php +++ b/tests/Zend/Form/TestAsset/decorators/TableRow.php @@ -23,9 +23,6 @@ use Zend\Form\Decorator\AbstractDecorator; -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - - /** * Mock file for testbed * diff --git a/tests/Zend/Http/CookieJarTest.php b/tests/Zend/Http/CookieJarTest.php index fe9d7936ef6..a16e3199428 100644 --- a/tests/Zend/Http/CookieJarTest.php +++ b/tests/Zend/Http/CookieJarTest.php @@ -26,11 +26,6 @@ use Zend\Http; use Zend\Http\Response; -/** - * Test helper - */ - - /** * Zend_Http_CookieJar unit tests * diff --git a/tests/Zend/Json/Server/CacheTest.php b/tests/Zend/Json/Server/CacheTest.php index a4e777bc6ab..30a17ac1606 100644 --- a/tests/Zend/Json/Server/CacheTest.php +++ b/tests/Zend/Json/Server/CacheTest.php @@ -134,7 +134,3 @@ public function baz() } -// Call Zend_JSON_Server_CacheTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_JSON_Server_CacheTest::main") { - \Zend_JSON_Server_CacheTest::main(); -} diff --git a/tests/Zend/Json/Server/ErrorTest.php b/tests/Zend/Json/Server/ErrorTest.php index 60ce97916e2..3330df87989 100644 --- a/tests/Zend/Json/Server/ErrorTest.php +++ b/tests/Zend/Json/Server/ErrorTest.php @@ -26,13 +26,6 @@ use Zend\Json\Server; use Zend\Json; -// Call Zend_JSON_Server_ErrorTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_JSON_Server_ErrorTest::main"); -} - - - /** * Test class for Zend_JSON_Server_Error * @@ -46,18 +39,6 @@ */ class ErrorTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - - $suite = new \PHPUnit_Framework_TestSuite("Zend_JSON_Server_ErrorTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Sets up the fixture, for example, open a network connection. * This method is called before a test is executed. @@ -184,8 +165,3 @@ public function validateArray($error) $this->assertSame($this->error->getData(), $error['data']); } } - -// Call Zend_JSON_Server_ErrorTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_JSON_Server_ErrorTest::main") { - \Zend_JSON_Server_ErrorTest::main(); -} diff --git a/tests/Zend/Layout/FunctionalTest.php b/tests/Zend/Layout/FunctionalTest.php index cb4fb0c85e6..f56b5b4cf35 100644 --- a/tests/Zend/Layout/FunctionalTest.php +++ b/tests/Zend/Layout/FunctionalTest.php @@ -75,4 +75,3 @@ public function testMissingViewScriptDoesDoubleRender() $this->assertEquals(trim($this->response->getBody()), "[DEFAULT_LAYOUT_START]\n[DEFAULT_LAYOUT_START]\n[DEFAULT_LAYOUT_END]\n(ErrorController::errorAction output)[DEFAULT_LAYOUT_END]"); } } - diff --git a/tests/Zend/Loader/AutoloadableClass.php b/tests/Zend/Loader/AutoloadableClass.php index 4d7b785e6ed..6ad6a12a9bf 100644 --- a/tests/Zend/Loader/AutoloadableClass.php +++ b/tests/Zend/Loader/AutoloadableClass.php @@ -26,9 +26,6 @@ * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - class Zend_Loader_AutoloadableClass { } diff --git a/tests/Zend/Loader/AutoloaderMultiVersionTest.php b/tests/Zend/Loader/AutoloaderMultiVersionTest.php index 8f912c40b65..f42c5924d74 100644 --- a/tests/Zend/Loader/AutoloaderMultiVersionTest.php +++ b/tests/Zend/Loader/AutoloaderMultiVersionTest.php @@ -23,6 +23,9 @@ use Zend\Loader\Autoloader; +require_once "PHPUnit/Framework/Error/Notice.php"; +require_once "PHPUnit/Framework/TestFailure.php"; + /** * @category Zend * @package Zend_Loader diff --git a/tests/Zend/Loader/LoaderTest.php b/tests/Zend/Loader/LoaderTest.php index 52cf2570cf7..ce45c28cf8c 100644 --- a/tests/Zend/Loader/LoaderTest.php +++ b/tests/Zend/Loader/LoaderTest.php @@ -28,9 +28,9 @@ * @category Zend * @package Loader * @subpackage UnitTests + * @group Zend_Loader * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Loader */ class LoaderTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Loader/MyLoader.php b/tests/Zend/Loader/MyLoader.php index e38580af6ab..882de664605 100644 --- a/tests/Zend/Loader/MyLoader.php +++ b/tests/Zend/Loader/MyLoader.php @@ -19,12 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * @see Zend_Loader - */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Static methods for loading classes and files. * @@ -34,7 +28,6 @@ * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ - class Zend_Loader_MyLoader extends Zend_Loader { public static function loadClass($class, $dirs = null) diff --git a/tests/Zend/Loader/MyOverloader.php b/tests/Zend/Loader/MyOverloader.php index 70ed44a1c0d..111bfa45ca0 100644 --- a/tests/Zend/Loader/MyOverloader.php +++ b/tests/Zend/Loader/MyOverloader.php @@ -19,12 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * @see Zend_Loader - */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Static methods for loading classes and files. * @@ -34,7 +28,6 @@ * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ - class Zend_Loader_MyOverloader extends Zend_Loader { public static function loadClass($class, $dirs = null) diff --git a/tests/Zend/Loader/_files/ZfTest/CacheTest.php b/tests/Zend/Loader/_files/ZfTest/CacheTest.php index 38a41a98a94..ef73559da58 100644 --- a/tests/Zend/Loader/_files/ZfTest/CacheTest.php +++ b/tests/Zend/Loader/_files/ZfTest/CacheTest.php @@ -21,8 +21,6 @@ namespace ZfTest; -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Loader diff --git a/tests/Zend/Loader/_files/ZfTest/FormSubmit.php b/tests/Zend/Loader/_files/ZfTest/FormSubmit.php index 8803f254cc4..6f81bcb59d5 100644 --- a/tests/Zend/Loader/_files/ZfTest/FormSubmit.php +++ b/tests/Zend/Loader/_files/ZfTest/FormSubmit.php @@ -21,8 +21,6 @@ namespace ZfTest; -\PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * @category Zend * @package Zend_Loader diff --git a/tests/Zend/Loader/_files/_testDir1/Class1.php b/tests/Zend/Loader/_files/_testDir1/Class1.php index 0b6186ab55c..ce52aa0cf66 100644 --- a/tests/Zend/Loader/_files/_testDir1/Class1.php +++ b/tests/Zend/Loader/_files/_testDir1/Class1.php @@ -19,9 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Empty class that is used in unit testing by ZendTest::testLoadClassValid() * diff --git a/tests/Zend/Loader/_files/_testDir1/Class1/Subclass2.php b/tests/Zend/Loader/_files/_testDir1/Class1/Subclass2.php index ade882cc478..8eba91eba0a 100644 --- a/tests/Zend/Loader/_files/_testDir1/Class1/Subclass2.php +++ b/tests/Zend/Loader/_files/_testDir1/Class1/Subclass2.php @@ -19,9 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Empty class that is used in unit testing by ZendTest::testLoadClassValid() * diff --git a/tests/Zend/Loader/_files/_testDir1/Class3.php b/tests/Zend/Loader/_files/_testDir1/Class3.php index 449dfa0079d..e87c68af0fd 100644 --- a/tests/Zend/Loader/_files/_testDir1/Class3.php +++ b/tests/Zend/Loader/_files/_testDir1/Class3.php @@ -19,9 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Empty class that is used in unit testing by ZendTest::testLoadClassValid() * diff --git a/tests/Zend/Loader/_files/_testDir1/Class4.php b/tests/Zend/Loader/_files/_testDir1/Class4.php index e0a9dbf0757..1d3c4c4c85d 100644 --- a/tests/Zend/Loader/_files/_testDir1/Class4.php +++ b/tests/Zend/Loader/_files/_testDir1/Class4.php @@ -19,9 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Empty class that is used in unit testing by ZendTest::testLoadClassValid() * diff --git a/tests/Zend/Loader/_files/_testDir1/ClassNonexistent.php b/tests/Zend/Loader/_files/_testDir1/ClassNonexistent.php index e4ec834ca0e..712b53013dd 100644 --- a/tests/Zend/Loader/_files/_testDir1/ClassNonexistent.php +++ b/tests/Zend/Loader/_files/_testDir1/ClassNonexistent.php @@ -19,9 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Empty file that is used in unit testing by ZendTest::testLoadClassNonexistent() * diff --git a/tests/Zend/Loader/_files/_testDir1/Interface1.php b/tests/Zend/Loader/_files/_testDir1/Interface1.php index 9f2541196a2..16ca85acd1d 100644 --- a/tests/Zend/Loader/_files/_testDir1/Interface1.php +++ b/tests/Zend/Loader/_files/_testDir1/Interface1.php @@ -19,9 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Empty class that is used in unit testing by ZendTest::testLoadInterfaceValid() * diff --git a/tests/Zend/Loader/_files/_testDir2/Class2.php b/tests/Zend/Loader/_files/_testDir2/Class2.php index bf9e8409d6f..1bcfa07d54e 100644 --- a/tests/Zend/Loader/_files/_testDir2/Class2.php +++ b/tests/Zend/Loader/_files/_testDir2/Class2.php @@ -19,9 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ - -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Empty class that is used in unit testing by ZendTest::testLoadClassSearchDirs() * diff --git a/tests/Zend/Memory/AccessControllerTest.php b/tests/Zend/Memory/AccessControllerTest.php index ea76af208dd..15805e794c4 100644 --- a/tests/Zend/Memory/AccessControllerTest.php +++ b/tests/Zend/Memory/AccessControllerTest.php @@ -46,12 +46,11 @@ class AccessControllerTest extends \PHPUnit_Framework_TestCase public function setUp() { - $this->_cache = Cache::factory('Core', 'File', + $this->_cache = \Zend\Cache\Cache::factory('Core', 'File', array('lifetime' => 1, 'automatic_serialization' => true), array('cache_dir' => __DIR__ . '/_files/')); } - public function tearDown() { $this->_cache->clean(Cache::CLEANING_MODE_ALL); diff --git a/tests/Zend/Navigation/NavigationTest.php b/tests/Zend/Navigation/NavigationTest.php index 17c819952b3..082b5b1bd24 100644 --- a/tests/Zend/Navigation/NavigationTest.php +++ b/tests/Zend/Navigation/NavigationTest.php @@ -25,11 +25,6 @@ namespace ZendTest\Navigation; use Zend\Navigation\Page; -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_NavigationTest::main'); -} - - /** * Zend_Navigation */ @@ -60,16 +55,6 @@ protected function tearDown() $this->_navigation = null; parent::tearDown(); } - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_NavigationTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } /** * Testing that navigation order is done correctly @@ -96,4 +81,4 @@ public function testNavigationArraySortsCorrectly() $this->assertEquals('page2', $pages[2]['uri']); } -} \ No newline at end of file +} diff --git a/tests/Zend/OAuth/ConsumerTest.php b/tests/Zend/OAuth/ConsumerTest.php index 8c1570b0e63..27d53ebdef1 100644 --- a/tests/Zend/OAuth/ConsumerTest.php +++ b/tests/Zend/OAuth/ConsumerTest.php @@ -1,9 +1,37 @@ canSendHeaders(true); - $name = $this->_normalizeHeader($name); - $value = (string) $value; - - if ($replace) { - foreach ($this->_headers as $key => $header) { - if ($name == $header['name']) { - unset($this->_headers[$key]); - } - } - } - - $this->_headers[] = array( - 'name' => $name, - 'value' => $value, - 'replace' => $replace - ); - - return $this; - } - - /** - * Set redirect URL - * - * Sets Location header and response code. Forces replacement of any prior - * redirects. - * - * @param string $url - * @param int $code - * @return Zend_Controller_Response_Abstract - */ - public function setRedirect($url, $code = 302) - { - $this->canSendHeaders(true); - $this->setHeader('Location', $url, true) - ->setHttpResponseCode($code); - - return $this; - } - - /** - * Is this a redirect? - * - * @return boolean - */ - public function isRedirect() - { - return $this->_isRedirect; - } - - /** - * Return array of headers; see {@link $_headers} for format - * - * @return array - */ - public function getHeaders() - { - return $this->_headers; - } - - /** - * Clear headers - * - * @return Zend_Controller_Response_Abstract - */ - public function clearHeaders() - { - $this->_headers = array(); - - return $this; - } - - /** - * Clears the specified HTTP header - * - * @param string $name - * @return Zend_Controller_Response_Abstract - */ - public function clearHeader($name) - { - if (! count($this->_headers)) { - return $this; - } - - foreach ($this->_headers as $index => $header) { - if ($name == $header['name']) { - unset($this->_headers[$index]); - } - } - - return $this; - } - - /** - * Set raw HTTP header - * - * Allows setting non key => value headers, such as status codes - * - * @param string $value - * @return Zend_Controller_Response_Abstract - */ - public function setRawHeader($value) - { - $this->canSendHeaders(true); - if ('Location' == substr($value, 0, 8)) { - $this->_isRedirect = true; - } - $this->_headersRaw[] = (string) $value; - return $this; - } - - /** - * Retrieve all {@link setRawHeader() raw HTTP headers} - * - * @return array - */ - public function getRawHeaders() - { - return $this->_headersRaw; - } - - /** - * Clear all {@link setRawHeader() raw HTTP headers} - * - * @return Zend_Controller_Response_Abstract - */ - public function clearRawHeaders() - { - $this->_headersRaw = array(); - return $this; - } - - /** - * Clears the specified raw HTTP header - * - * @param string $headerRaw - * @return Zend_Controller_Response_Abstract - */ - public function clearRawHeader($headerRaw) - { - if (! count($this->_headersRaw)) { - return $this; - } - - $key = array_search($headerRaw, $this->_headersRaw); - unset($this->_headersRaw[$key]); - - return $this; - } - - /** - * Clear all headers, normal and raw - * - * @return Zend_Controller_Response_Abstract - */ - public function clearAllHeaders() - { - return $this->clearHeaders() - ->clearRawHeaders(); - } - - /** - * Set HTTP response code to use with headers - * - * @param int $code - * @return Zend_Controller_Response_Abstract - */ - public function setHttpResponseCode($code) - { - if (!is_int($code) || (100 > $code) || (599 < $code)) { - throw new Zend_Controller_Response_Exception('Invalid HTTP response code'); - } - - if ((300 <= $code) && (307 >= $code)) { - $this->_isRedirect = true; - } else { - $this->_isRedirect = false; - } - - $this->_httpResponseCode = $code; - return $this; - } - - /** - * Retrieve HTTP response code - * - * @return int - */ - public function getHttpResponseCode() - { - return $this->_httpResponseCode; - } - - /** - * Can we send headers? - * - * @param boolean $throw Whether or not to throw an exception if headers have been sent; defaults to false - * @return boolean - * @throws Zend_Controller_Response_Exception - */ - public function canSendHeaders($throw = false) - { - $ok = headers_sent($file, $line); - if ($ok && $throw && $this->headersSentThrowsException) { - throw new Zend_Controller_Response_Exception('Cannot send headers; headers already sent in ' . $file . ', line ' . $line); - } - - return !$ok; - } - - /** - * Send all headers - * - * Sends any headers specified. If an {@link setHttpResponseCode() HTTP response code} - * has been specified, it is sent with the first header. - * - * @return Zend_Controller_Response_Abstract - */ - public function sendHeaders() - { - // Only check if we can send headers if we have headers to send - if (count($this->_headersRaw) || count($this->_headers) || (200 != $this->_httpResponseCode)) { - $this->canSendHeaders(true); - } elseif (200 == $this->_httpResponseCode) { - // Haven't changed the response code, and we have no headers - return $this; - } - - $httpCodeSent = false; - - foreach ($this->_headersRaw as $header) { - if (!$httpCodeSent && $this->_httpResponseCode) { - header($header, true, $this->_httpResponseCode); - $httpCodeSent = true; - } else { - header($header); - } - } - - foreach ($this->_headers as $header) { - if (!$httpCodeSent && $this->_httpResponseCode) { - header($header['name'] . ': ' . $header['value'], $header['replace'], $this->_httpResponseCode); - $httpCodeSent = true; - } else { - header($header['name'] . ': ' . $header['value'], $header['replace']); - } - } - - if (!$httpCodeSent) { - header('HTTP/1.1 ' . $this->_httpResponseCode); - $httpCodeSent = true; - } - - return $this; - } - - /** - * Set body content - * - * If $name is not passed, or is not a string, resets the entire body and - * sets the 'default' key to $content. - * - * If $name is a string, sets the named segment in the body array to - * $content. - * - * @param string $content - * @param null|string $name - * @return Zend_Controller_Response_Abstract - */ - public function setBody($content, $name = null) - { - if ((null === $name) || !is_string($name)) { - $this->_body = array('default' => (string) $content); - } else { - $this->_body[$name] = (string) $content; - } - - return $this; - } - - /** - * Append content to the body content - * - * @param string $content - * @param null|string $name - * @return Zend_Controller_Response_Abstract - */ - public function appendBody($content, $name = null) - { - if ((null === $name) || !is_string($name)) { - if (isset($this->_body['default'])) { - $this->_body['default'] .= (string) $content; - } else { - return $this->append('default', $content); - } - } elseif (isset($this->_body[$name])) { - $this->_body[$name] .= (string) $content; - } else { - return $this->append($name, $content); - } - - return $this; - } - - /** - * Clear body array - * - * With no arguments, clears the entire body array. Given a $name, clears - * just that named segment; if no segment matching $name exists, returns - * false to indicate an error. - * - * @param string $name Named segment to clear - * @return boolean - */ - public function clearBody($name = null) - { - if (null !== $name) { - $name = (string) $name; - if (isset($this->_body[$name])) { - unset($this->_body[$name]); - return true; - } - - return false; - } - - $this->_body = array(); - return true; - } - - /** - * Return the body content - * - * If $spec is false, returns the concatenated values of the body content - * array. If $spec is boolean true, returns the body content array. If - * $spec is a string and matches a named segment, returns the contents of - * that segment; otherwise, returns null. - * - * @param boolean $spec - * @return string|array|null - */ - public function getBody($spec = false) - { - if (false === $spec) { - ob_start(); - $this->outputBody(); - return ob_get_clean(); - } elseif (true === $spec) { - return $this->_body; - } elseif (is_string($spec) && isset($this->_body[$spec])) { - return $this->_body[$spec]; - } - - return null; - } - - /** - * Append a named body segment to the body content array - * - * If segment already exists, replaces with $content and places at end of - * array. - * - * @param string $name - * @param string $content - * @return Zend_Controller_Response_Abstract - */ - public function append($name, $content) - { - if (!is_string($name)) { - throw new Zend_Controller_Response_Exception('Invalid body segment key ("' . gettype($name) . '")'); - } - - if (isset($this->_body[$name])) { - unset($this->_body[$name]); - } - $this->_body[$name] = (string) $content; - return $this; - } - - /** - * Prepend a named body segment to the body content array - * - * If segment already exists, replaces with $content and places at top of - * array. - * - * @param string $name - * @param string $content - * @return void - */ - public function prepend($name, $content) - { - if (!is_string($name)) { - throw new Zend_Controller_Response_Exception('Invalid body segment key ("' . gettype($name) . '")'); - } - - if (isset($this->_body[$name])) { - unset($this->_body[$name]); - } - - $new = array($name => (string) $content); - $this->_body = $new + $this->_body; - - return $this; - } - - /** - * Insert a named segment into the body content array - * - * @param string $name - * @param string $content - * @param string $parent - * @param boolean $before Whether to insert the new segment before or - * after the parent. Defaults to false (after) - * @return Zend_Controller_Response_Abstract - */ - public function insert($name, $content, $parent = null, $before = false) - { - if (!is_string($name)) { - throw new Zend_Controller_Response_Exception('Invalid body segment key ("' . gettype($name) . '")'); - } - - if ((null !== $parent) && !is_string($parent)) { - throw new Zend_Controller_Response_Exception('Invalid body segment parent key ("' . gettype($parent) . '")'); - } - - if (isset($this->_body[$name])) { - unset($this->_body[$name]); - } - - if ((null === $parent) || !isset($this->_body[$parent])) { - return $this->append($name, $content); - } - - $ins = array($name => (string) $content); - $keys = array_keys($this->_body); - $loc = array_search($parent, $keys); - if (!$before) { - // Increment location if not inserting before - ++$loc; - } - - if (0 === $loc) { - // If location of key is 0, we're prepending - $this->_body = $ins + $this->_body; - } elseif ($loc >= (count($this->_body))) { - // If location of key is maximal, we're appending - $this->_body = $this->_body + $ins; - } else { - // Otherwise, insert at location specified - $pre = array_slice($this->_body, 0, $loc); - $post = array_slice($this->_body, $loc); - $this->_body = $pre + $ins + $post; - } - - return $this; - } - - /** - * Echo the body segments - * - * @return void - */ - public function outputBody() - { - $body = implode('', $this->_body); - echo $body; - } - - /** - * Register an exception with the response - * - * @param Exception $e - * @return Zend_Controller_Response_Abstract - */ - public function setException(Exception $e) - { - $this->_exceptions[] = $e; - return $this; - } - - /** - * Retrieve the exception stack - * - * @return array - */ - public function getException() - { - return $this->_exceptions; - } - - /** - * Has an exception been registered with the response? - * - * @return boolean - */ - public function isException() - { - return !empty($this->_exceptions); - } - - /** - * Does the response object contain an exception of a given type? - * - * @param string $type - * @return boolean - */ - public function hasExceptionOfType($type) - { - foreach ($this->_exceptions as $e) { - if ($e instanceof $type) { - return true; - } - } - - return false; - } - - /** - * Does the response object contain an exception with a given message? - * - * @param string $message - * @return boolean - */ - public function hasExceptionOfMessage($message) - { - foreach ($this->_exceptions as $e) { - if ($message == $e->getMessage()) { - return true; - } - } - - return false; - } - - /** - * Does the response object contain an exception with a given code? - * - * @param int $code - * @return boolean - */ - public function hasExceptionOfCode($code) - { - $code = (int) $code; - foreach ($this->_exceptions as $e) { - if ($code == $e->getCode()) { - return true; - } - } - - return false; - } - - /** - * Retrieve all exceptions of a given type - * - * @param string $type - * @return false|array - */ - public function getExceptionByType($type) - { - $exceptions = array(); - foreach ($this->_exceptions as $e) { - if ($e instanceof $type) { - $exceptions[] = $e; - } - } - - if (empty($exceptions)) { - $exceptions = false; - } - - return $exceptions; - } - - /** - * Retrieve all exceptions of a given message - * - * @param string $message - * @return false|array - */ - public function getExceptionByMessage($message) - { - $exceptions = array(); - foreach ($this->_exceptions as $e) { - if ($message == $e->getMessage()) { - $exceptions[] = $e; - } - } - - if (empty($exceptions)) { - $exceptions = false; - } - - return $exceptions; - } - - /** - * Retrieve all exceptions of a given code - * - * @param mixed $code - * @return void - */ - public function getExceptionByCode($code) - { - $code = (int) $code; - $exceptions = array(); - foreach ($this->_exceptions as $e) { - if ($code == $e->getCode()) { - $exceptions[] = $e; - } - } - - if (empty($exceptions)) { - $exceptions = false; - } - - return $exceptions; - } - - /** - * Whether or not to render exceptions (off by default) - * - * If called with no arguments or a null argument, returns the value of the - * flag; otherwise, sets it and returns the current value. - * - * @param boolean $flag Optional - * @return boolean - */ - public function renderExceptions($flag = null) - { - if (null !== $flag) { - $this->_renderExceptions = $flag ? true : false; - } - - return $this->_renderExceptions; - } - - /** - * Send the response, including all headers, rendering exceptions if so - * requested. - * - * @return void - */ - public function sendResponse() - { - $this->sendHeaders(); - - if ($this->isException() && $this->renderExceptions()) { - $exceptions = ''; - foreach ($this->getException() as $e) { - $exceptions .= $e->__toString() . "\n"; - } - echo $exceptions; - return; - } - - $this->outputBody(); - } - - /** - * Magic __toString functionality - * - * Proxies to {@link sendResponse()} and returns response value as string - * using output buffering. - * - * @return string - */ - public function __toString() - { - ob_start(); - $this->sendResponse(); - return ob_get_clean(); - } -} - diff --git a/tests/Zend/Paginator/_files/test.sqlite b/tests/Zend/Paginator/_files/test.sqlite index 5eebdfce04c..21c8f8b0af2 100644 Binary files a/tests/Zend/Paginator/_files/test.sqlite and b/tests/Zend/Paginator/_files/test.sqlite differ diff --git a/tests/Zend/Serializer/Adapter/Amf0Test.php b/tests/Zend/Serializer/Adapter/Amf0Test.php index 69b8b0618da..9d50abc5c94 100644 --- a/tests/Zend/Serializer/Adapter/Amf0Test.php +++ b/tests/Zend/Serializer/Adapter/Amf0Test.php @@ -30,6 +30,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/Adapter/Amf3Test.php b/tests/Zend/Serializer/Adapter/Amf3Test.php index 1f79debce69..7296b16d797 100644 --- a/tests/Zend/Serializer/Adapter/Amf3Test.php +++ b/tests/Zend/Serializer/Adapter/Amf3Test.php @@ -30,6 +30,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/Adapter/IgBinaryTest.php b/tests/Zend/Serializer/Adapter/IgBinaryTest.php index ea4a0d9b78d..84458475e55 100644 --- a/tests/Zend/Serializer/Adapter/IgBinaryTest.php +++ b/tests/Zend/Serializer/Adapter/IgBinaryTest.php @@ -31,6 +31,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/Adapter/JsonTest.php b/tests/Zend/Serializer/Adapter/JsonTest.php index ec4cc76162c..64a87bb1da1 100644 --- a/tests/Zend/Serializer/Adapter/JsonTest.php +++ b/tests/Zend/Serializer/Adapter/JsonTest.php @@ -30,6 +30,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/Adapter/PhpCodeTest.php b/tests/Zend/Serializer/Adapter/PhpCodeTest.php index 6808a89ba15..11d2627aee7 100644 --- a/tests/Zend/Serializer/Adapter/PhpCodeTest.php +++ b/tests/Zend/Serializer/Adapter/PhpCodeTest.php @@ -30,6 +30,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/Adapter/PhpSerializeTest.php b/tests/Zend/Serializer/Adapter/PhpSerializeTest.php index b23a1d946b9..6cd9ff5b2ee 100644 --- a/tests/Zend/Serializer/Adapter/PhpSerializeTest.php +++ b/tests/Zend/Serializer/Adapter/PhpSerializeTest.php @@ -30,6 +30,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/Adapter/PythonPickleSerializeProtocol0Test.php b/tests/Zend/Serializer/Adapter/PythonPickleSerializeProtocol0Test.php index c9d1d1cabc3..405ee4bfb3f 100644 --- a/tests/Zend/Serializer/Adapter/PythonPickleSerializeProtocol0Test.php +++ b/tests/Zend/Serializer/Adapter/PythonPickleSerializeProtocol0Test.php @@ -30,6 +30,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/Adapter/PythonPickleSerializeProtocol1Test.php b/tests/Zend/Serializer/Adapter/PythonPickleSerializeProtocol1Test.php index 338571c98d8..0f8b281cc80 100644 --- a/tests/Zend/Serializer/Adapter/PythonPickleSerializeProtocol1Test.php +++ b/tests/Zend/Serializer/Adapter/PythonPickleSerializeProtocol1Test.php @@ -30,6 +30,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/Adapter/PythonPickleUnserializeTest.php b/tests/Zend/Serializer/Adapter/PythonPickleUnserializeTest.php index b745c27e515..0db4a5c8878 100644 --- a/tests/Zend/Serializer/Adapter/PythonPickleUnserializeTest.php +++ b/tests/Zend/Serializer/Adapter/PythonPickleUnserializeTest.php @@ -30,6 +30,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/Adapter/WddxTest.php b/tests/Zend/Serializer/Adapter/WddxTest.php index f339dcbabf1..15b010f0dea 100644 --- a/tests/Zend/Serializer/Adapter/WddxTest.php +++ b/tests/Zend/Serializer/Adapter/WddxTest.php @@ -31,6 +31,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Serializer/SerializerTest.php b/tests/Zend/Serializer/SerializerTest.php index 8cbf93fca5f..c3ecf32173f 100644 --- a/tests/Zend/Serializer/SerializerTest.php +++ b/tests/Zend/Serializer/SerializerTest.php @@ -34,6 +34,7 @@ * @category Zend * @package Zend_Serializer * @subpackage UnitTests + * @group Zend_Serializer * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Server/ReflectionTest.php b/tests/Zend/Server/ReflectionTest.php index 14ad280db5e..f4afbd91351 100644 --- a/tests/Zend/Server/ReflectionTest.php +++ b/tests/Zend/Server/ReflectionTest.php @@ -66,7 +66,7 @@ public function testReflectClassThrowsExceptionOnInvalidParameter() */ public function testReflectClass2() { - $reflection = Reflection\Reflection::reflectClass('ZendTest\Server\ReflectionTestClass', false, 'zsr'); + $reflection = Reflection::reflectClass('ZendTest\Server\ReflectionTestClass', false, 'zsr'); $this->assertEquals('zsr', $reflection->getNamespace()); } @@ -96,7 +96,7 @@ public function testReflectFunctionThrowsExceptionOnInvalidParam() */ public function testReflectFunction2() { - $reflection = Reflection\Reflection::reflectFunction('ZendTest\Server\reflectionTestFunction', false, 'zsr'); + $reflection = Reflection::reflectFunction('ZendTest\Server\reflectionTestFunction', false, 'zsr'); $this->assertEquals('zsr', $reflection->getNamespace()); } } diff --git a/tests/Zend/Service/DeveloperGarden/AllOfflineTests.php b/tests/Zend/Service/DeveloperGarden/AllOfflineTests.php index f13ff7fd4ae..2dd3865da26 100644 --- a/tests/Zend/Service/DeveloperGarden/AllOfflineTests.php +++ b/tests/Zend/Service/DeveloperGarden/AllOfflineTests.php @@ -19,15 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_AllTests::main'); -} - -/** - * Test helper - */ - - /** * Zend_Service_DeveloperGarden test suite * @@ -39,11 +30,6 @@ */ class Zend_Service_DeveloperGarden_AllOfflineTests { - public static function main() - { - PHPUnit_TextUI_TestRunner::run(self::suite()); - } - public static function suite() { $suite = new PHPUnit_Framework_TestSuite('Zend Framework - Zend_Service - DeveloperGarden - Offline'); @@ -59,7 +45,3 @@ public static function suite() return $suite; } } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_AllOfflineTests::main') { - Zend_Service_DeveloperGarden_AllOfflineTests::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/AllOnlineTests.php b/tests/Zend/Service/DeveloperGarden/AllOnlineTests.php index 9023fd10e4f..46a7e3df733 100644 --- a/tests/Zend/Service/DeveloperGarden/AllOnlineTests.php +++ b/tests/Zend/Service/DeveloperGarden/AllOnlineTests.php @@ -19,15 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_AllTests::main'); -} - -/** - * Test helper - */ - - /** * Zend_Service_DeveloperGarden test suite * @@ -39,11 +30,6 @@ */ class Zend_Service_DeveloperGarden_AllOnlineTests { - public static function main() - { - PHPUnit_TextUI_TestRunner::run(self::suite()); - } - public static function suite() { $suite = new PHPUnit_Framework_TestSuite('Zend Framework - Zend_Service - DeveloperGarden - Online'); @@ -60,7 +46,3 @@ public static function suite() return $suite; } } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_AllOnlineTests::main') { - Zend_Service_DeveloperGarden_AllOnlineTests::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/BaseUserServiceTest.php b/tests/Zend/Service/DeveloperGarden/BaseUserServiceTest.php index 7908ec97e83..12543e68411 100644 --- a/tests/Zend/Service/DeveloperGarden/BaseUserServiceTest.php +++ b/tests/Zend/Service/DeveloperGarden/BaseUserServiceTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_BaseUserServiceTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_BaseUserService */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -53,12 +47,6 @@ class Zend_Service_DeveloperGarden_BaseUserServiceTest extends PHPUnit_Framework protected $_limit = 10; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_ENABLED') || @@ -247,7 +235,3 @@ public function buildModuleString($module, $environment) return $this->_buildModuleString($module, $environment); } } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_BaseUserServiceTest::main') { - Zend_Service_DeveloperGarden_BaseUserServiceTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/ConferenceCallTest.php b/tests/Zend/Service/DeveloperGarden/ConferenceCallTest.php index 11c7f263f47..71b27f39ac1 100644 --- a/tests/Zend/Service/DeveloperGarden/ConferenceCallTest.php +++ b/tests/Zend/Service/DeveloperGarden/ConferenceCallTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_ConferenceCallTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_ConferenceCall */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_ConferenceCallTest extends PHPUnit_Framework_ */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_ENABLED') || @@ -1833,6 +1821,3 @@ class Zend_Service_DeveloperGarden_ConferenceCall_Mock { } -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_ConferenceCallTest::main') { - Zend_Service_DeveloperGarden_ConferenceCallTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/IpLocationTest.php b/tests/Zend/Service/DeveloperGarden/IpLocationTest.php index 03b972d949e..861d2ab44ac 100644 --- a/tests/Zend/Service/DeveloperGarden/IpLocationTest.php +++ b/tests/Zend/Service/DeveloperGarden/IpLocationTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_IpLocationTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_IpLocation */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_IpLocationTest extends PHPUnit_Framework_Test */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_ENABLED') || @@ -116,7 +104,3 @@ class Zend_Service_DeveloperGarden_IpLocation_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_IpLocationTest::main') { - Zend_Service_DeveloperGarden_IpLocationTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/LocalSearchTest.php b/tests/Zend/Service/DeveloperGarden/LocalSearchTest.php index 60a5faa311d..693dd73d003 100644 --- a/tests/Zend/Service/DeveloperGarden/LocalSearchTest.php +++ b/tests/Zend/Service/DeveloperGarden/LocalSearchTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_LocalSearchTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_LocalSearch */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_LocalSearchTest extends PHPUnit_Framework_Tes */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_ENABLED') || @@ -108,7 +96,3 @@ class Zend_Service_DeveloperGarden_LocalSearch_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_LocalSearchTest::main') { - Zend_Service_DeveloperGarden_LocalSearchTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/OfflineBaseUserServiceTest.php b/tests/Zend/Service/DeveloperGarden/OfflineBaseUserServiceTest.php index 4b2f7e53118..f04455ed8fa 100644 --- a/tests/Zend/Service/DeveloperGarden/OfflineBaseUserServiceTest.php +++ b/tests/Zend/Service/DeveloperGarden/OfflineBaseUserServiceTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_BaseUserServiceTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_BaseUserService */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -53,12 +47,6 @@ class Zend_Service_DeveloperGarden_OfflineBaseUserServiceTest extends PHPUnit_Fr protected $_limit = 10; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_LOGIN')) { @@ -197,7 +185,3 @@ public function buildModuleString($module, $environment) return $this->_buildModuleString($module, $environment); } } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_OfflineBaseUserServiceTest::main') { - Zend_Service_DeveloperGarden_OfflineBaseUserServiceTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/OfflineClientTest.php b/tests/Zend/Service/DeveloperGarden/OfflineClientTest.php index d4ec6be5322..0bf187e6094 100644 --- a/tests/Zend/Service/DeveloperGarden/OfflineClientTest.php +++ b/tests/Zend/Service/DeveloperGarden/OfflineClientTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_CredentialTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_IpLocation */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_OfflineClientTest extends PHPUnit_Framework_T */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_LOGIN')) { @@ -294,7 +282,3 @@ class Zend_Service_DeveloperGarden_OfflineClientIncompleteWsdlFileLocal_Mock { protected $_wsdlFileLocal = null; } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_OfflineCredentialTest::main') { - Zend_Service_DeveloperGarden_OfflineCredentialTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/OfflineConferenceCallTest.php b/tests/Zend/Service/DeveloperGarden/OfflineConferenceCallTest.php index f5908791146..6428507e282 100644 --- a/tests/Zend/Service/DeveloperGarden/OfflineConferenceCallTest.php +++ b/tests/Zend/Service/DeveloperGarden/OfflineConferenceCallTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_ConferenceCallTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_ConferenceCall */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_OfflineConferenceCallTest extends PHPUnit_Fra */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_LOGIN')) { @@ -228,8 +216,4 @@ public function testParticipantStatus() class Zend_Service_DeveloperGarden_OfflineConferenceCall_Mock extends Zend_Service_DeveloperGarden_ConferenceCall { - -} -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_OfflineConferenceCallTest::main') { - Zend_Service_DeveloperGarden_OfflineConferenceCallTest::main(); } diff --git a/tests/Zend/Service/DeveloperGarden/OfflineCredentialTest.php b/tests/Zend/Service/DeveloperGarden/OfflineCredentialTest.php index 76529b21d77..8c458cb8495 100644 --- a/tests/Zend/Service/DeveloperGarden/OfflineCredentialTest.php +++ b/tests/Zend/Service/DeveloperGarden/OfflineCredentialTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_CredentialTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_Credential */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_OfflineCredentialTest extends PHPUnit_Framewo */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_LOGIN')) { @@ -203,7 +191,3 @@ class Zend_Service_DeveloperGarden_OfflineCredential_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_OfflineCredentialTest::main') { - Zend_Service_DeveloperGarden_OfflineCredentialTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/OfflineIpLocationTest.php b/tests/Zend/Service/DeveloperGarden/OfflineIpLocationTest.php index 3cdd30dc26b..c1920ab9cbc 100644 --- a/tests/Zend/Service/DeveloperGarden/OfflineIpLocationTest.php +++ b/tests/Zend/Service/DeveloperGarden/OfflineIpLocationTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_IpLocationTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_IpLocation */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_OfflineIpLocationTest extends PHPUnit_Framewo */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_LOGIN')) { @@ -91,7 +79,3 @@ class Zend_Service_DeveloperGarden_OfflineIpLocation_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_OfflineIpLocationTest::main') { - Zend_Service_DeveloperGarden_OfflineIpLocationTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/OfflineLocalSearchParametersTest.php b/tests/Zend/Service/DeveloperGarden/OfflineLocalSearchParametersTest.php index 88dd77eb901..04aa7bfcda7 100644 --- a/tests/Zend/Service/DeveloperGarden/OfflineLocalSearchParametersTest.php +++ b/tests/Zend/Service/DeveloperGarden/OfflineLocalSearchParametersTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_LocalSearchTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_LocalSearch */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -51,12 +45,6 @@ class Zend_Service_DeveloperGarden_OfflineLocalSearchParametersTest extends PHPU */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_LOGIN')) { @@ -207,7 +195,3 @@ class Zend_Service_DeveloperGarden_OfflineLocalSearch_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_OfflineLocalSearchParametersTest::main') { - Zend_Service_DeveloperGarden_OfflineLocalSearchParametersTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/OfflineSecurityTokenServerTest.php b/tests/Zend/Service/DeveloperGarden/OfflineSecurityTokenServerTest.php index febfd0c12d0..bf877ba83b4 100644 --- a/tests/Zend/Service/DeveloperGarden/OfflineSecurityTokenServerTest.php +++ b/tests/Zend/Service/DeveloperGarden/OfflineSecurityTokenServerTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_SecurityTokenServerTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_SecurityTokenServer */ @@ -41,6 +33,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -51,12 +45,6 @@ class Zend_Service_DeveloperGarden_OfflineSecurityTokenServerTest extends PHPUni */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { Zend_Service_DeveloperGarden_SecurityTokenServer_Cache::removeCache(); @@ -228,24 +216,24 @@ public function testTokenCacheGetCache() public function testTokenCacheSetCache() { - $cache = Zend_Cache::factory('Core', 'File', array(), array()); + $cache = Zend\Cache\Cache::factory('Core', 'File', array(), array()); $this->assertNull( Zend_Service_DeveloperGarden_SecurityTokenServer_Cache::setCache($cache) ); $this->assertType( - 'Zend_Cache_Core', + 'Zend\\Cache\\Frontend\\Core', Zend_Service_DeveloperGarden_SecurityTokenServer_Cache::getCache() ); } public function testTokenCacheRemoveCache() { - $cache = Zend_Cache::factory('Core', 'File', array(), array()); + $cache = Zend\Cache\Cache::factory('Core', 'File', array(), array()); $this->assertNull( Zend_Service_DeveloperGarden_SecurityTokenServer_Cache::setCache($cache) ); $this->assertType( - 'Zend_Cache_Core', + 'Zend\\Cache\\Frontend\\Core', Zend_Service_DeveloperGarden_SecurityTokenServer_Cache::getCache() ); @@ -257,12 +245,12 @@ public function testTokenCacheRemoveCache() public function testTokenCacheClearCache() { - $cache = Zend_Cache::factory('Core', 'File', array(), array()); + $cache = Zend\Cache\Cache::factory('Core', 'File', array(), array()); $this->assertNull( Zend_Service_DeveloperGarden_SecurityTokenServer_Cache::setCache($cache) ); $this->assertType( - 'Zend_Cache_Core', + 'Zend\\Cache\\Frontend\\Core', Zend_Service_DeveloperGarden_SecurityTokenServer_Cache::getCache() ); @@ -276,12 +264,12 @@ public function testTokenCacheGetTokenFromCacheWithZendCache() 'getTokens' ); - $cache = Zend_Cache::factory('Core', 'File', array(), array()); + $cache = Zend\Cache\Cache::factory('Core', 'File', array(), array()); $this->assertNull( Zend_Service_DeveloperGarden_SecurityTokenServer_Cache::setCache($cache) ); $this->assertType( - 'Zend_Cache_Core', + 'Zend\\Cache\\Frontend\\Core', Zend_Service_DeveloperGarden_SecurityTokenServer_Cache::getCache() ); @@ -300,7 +288,3 @@ class Zend_Service_DeveloperGarden_OfflineSecurityTokenServer_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_OfflineSecurityTokenServerTest::main') { - Zend_Service_DeveloperGarden_OfflineSecurityTokenServerTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/SecurityTokenServerTest.php b/tests/Zend/Service/DeveloperGarden/SecurityTokenServerTest.php index c12bdc9ad4e..4efac776be7 100644 --- a/tests/Zend/Service/DeveloperGarden/SecurityTokenServerTest.php +++ b/tests/Zend/Service/DeveloperGarden/SecurityTokenServerTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_SecurityTokenServerTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_SecurityTokenServer */ @@ -41,6 +33,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -51,12 +45,6 @@ class Zend_Service_DeveloperGarden_SecurityTokenServerTest extends PHPUnit_Frame */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_ENABLED') || @@ -156,7 +144,3 @@ class Zend_Service_DeveloperGarden_SecurityTokenServer_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_SecurityTokenServerTest::main') { - Zend_Service_DeveloperGarden_SecurityTokenServerTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/SendSmsTest.php b/tests/Zend/Service/DeveloperGarden/SendSmsTest.php index 5e0f57ad97a..9f6f5c2cebb 100644 --- a/tests/Zend/Service/DeveloperGarden/SendSmsTest.php +++ b/tests/Zend/Service/DeveloperGarden/SendSmsTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_SendSmsTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_SendSms */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_SendSmsTest extends PHPUnit_Framework_TestCas */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_ENABLED') || @@ -208,7 +196,3 @@ class Zend_Service_DeveloperGarden_SendSms_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_SendSmsTest::main') { - Zend_Service_DeveloperGarden_SendSmsTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/SmsValidationTest.php b/tests/Zend/Service/DeveloperGarden/SmsValidationTest.php index ffe6d728bba..4808b8a23c5 100644 --- a/tests/Zend/Service/DeveloperGarden/SmsValidationTest.php +++ b/tests/Zend/Service/DeveloperGarden/SmsValidationTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_SmsValidationTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_SmsValidation */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_SmsValidationTest extends PHPUnit_Framework_T */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_ENABLED') || @@ -86,7 +74,3 @@ class Zend_Service_DeveloperGarden_SmsValidation_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_SmsValidationTest::main') { - Zend_Service_DeveloperGarden_SmsValidationTest::main(); -} diff --git a/tests/Zend/Service/DeveloperGarden/VoiceCallTest.php b/tests/Zend/Service/DeveloperGarden/VoiceCallTest.php index 70b157b51d1..f85de4bc5e7 100644 --- a/tests/Zend/Service/DeveloperGarden/VoiceCallTest.php +++ b/tests/Zend/Service/DeveloperGarden/VoiceCallTest.php @@ -19,14 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_DeveloperGarden_VoiceCallTest::main'); -} - -/** - * Test helper - */ - /** * @see Zend_Service_DeveloperGarden_VoiceCall */ @@ -37,6 +29,8 @@ * @category Zend * @package Zend_Service_DeveloperGarden * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_DeveloperGarden * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,12 +41,6 @@ class Zend_Service_DeveloperGarden_VoiceCallTest extends PHPUnit_Framework_TestC */ protected $_service = null; - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!defined('TESTS_ZEND_SERVICE_DEVELOPERGARDEN_ONLINE_ENABLED') || @@ -487,7 +475,3 @@ class Zend_Service_DeveloperGarden_VoiceCall_Mock { } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_DeveloperGarden_VoiceCallTest::main') { - Zend_Service_DeveloperGarden_VoiceCallTest::main(); -} diff --git a/tests/Zend/Service/Flickr/OfflineTest.php b/tests/Zend/Service/Flickr/OfflineTest.php index fb2133349cc..34df04856b8 100644 --- a/tests/Zend/Service/Flickr/OfflineTest.php +++ b/tests/Zend/Service/Flickr/OfflineTest.php @@ -91,12 +91,12 @@ public function setUp() /** * @see Zend_Http_Client_Adapter_Socket */ - $this->_httpClientAdapterSocket = new Zend_Http_Client_Adapter_Socket(); + $this->_httpClientAdapterSocket = new Zend\Http\Client\Adapter\Socket(); /** * @see Zend_Http_Client_Adapter_Test */ - $this->_httpClientAdapterTest = new Zend_Http_Client_Adapter_Test(); + $this->_httpClientAdapterTest = new Zend\Http\Client\Adapter\Test(); } /** diff --git a/tests/Zend/Service/LiveDocx/LiveDocxTest.php b/tests/Zend/Service/LiveDocx/LiveDocxTest.php index 838ec915847..855853c2f11 100644 --- a/tests/Zend/Service/LiveDocx/LiveDocxTest.php +++ b/tests/Zend/Service/LiveDocx/LiveDocxTest.php @@ -27,10 +27,6 @@ namespace Zend\Service\LiveDocx; use Zend\Validator; -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_LiveDocx_LiveDocxTest::main'); -} - /** * Zend_Service_LiveDocx test case @@ -47,12 +43,6 @@ class LiveDocxTest extends \PHPUnit_Framework_TestCase { public $mailMerge; - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite(__CLASS__); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!constant('TESTS_ZEND_SERVICE_LIVEDOCX_USERNAME') @@ -127,7 +117,3 @@ public function testSetWSDLGetWSDLWithSoapClient() } } - -if (PHPUnit_MAIN_METHOD == 'LiveDocxTest::main') { - LiveDocxTest::main(); -} diff --git a/tests/Zend/Service/LiveDocx/MailMergeTest.php b/tests/Zend/Service/LiveDocx/MailMergeTest.php index ed5c670107d..3138a674f2b 100644 --- a/tests/Zend/Service/LiveDocx/MailMergeTest.php +++ b/tests/Zend/Service/LiveDocx/MailMergeTest.php @@ -27,10 +27,6 @@ use \Zend\Soap\Client\Client; -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'MailMergeTest::main'); -} - /** * Zend_Service_LiveDocx test case @@ -54,12 +50,6 @@ class MailMergeTest extends \PHPUnit_Framework_TestCase // ------------------------------------------------------------------------- - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite(__CLASS__); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { if (!constant('TESTS_ZEND_SERVICE_LIVEDOCX_USERNAME') @@ -629,7 +619,3 @@ public function testMultiAssocArrayToArrayOfArrayOfString() $this->assertEquals($expectedResults, $actualResults); } } - -if (PHPUnit_MAIN_METHOD == 'MailMergeTest::main') { - MailMergeTest::main(); -} diff --git a/tests/Zend/Service/Nirvanix/FunctionalTestCase.php b/tests/Zend/Service/Nirvanix/FunctionalTestCase.php index f95caa4d411..d4f9a1d544e 100644 --- a/tests/Zend/Service/Nirvanix/FunctionalTestCase.php +++ b/tests/Zend/Service/Nirvanix/FunctionalTestCase.php @@ -40,8 +40,8 @@ class Zend_Service_Nirvanix_FunctionalTestCase extends PHPUnit_Framework_TestCas { public function setUp() { - $this->httpAdapter = new Zend_Http_Client_Adapter_Test(); - $this->httpClient = new Zend_Http_Client('http://foo', + $this->httpAdapter = new Zend\Http\Client\Adapter\Test(); + $this->httpClient = new Zend\Http\Client('http://foo', array('adapter' => $this->httpAdapter)); $this->auth = array('username' => 'foo', 'password' => 'bar', 'appKey' => 'baz'); diff --git a/tests/Zend/Service/Nirvanix/Namespace/BaseTest.php b/tests/Zend/Service/Nirvanix/Namespace/BaseTest.php index b0d4146ab61..ac5be97dd01 100644 --- a/tests/Zend/Service/Nirvanix/Namespace/BaseTest.php +++ b/tests/Zend/Service/Nirvanix/Namespace/BaseTest.php @@ -20,12 +20,10 @@ */ /** - * @see Zend_Service_Nirvanix_Namespace_Base - */ - -/** - * @see Zend_Service_Nirvanix_FunctionalTestCase + * @todo: temporary fix because test autoloader doesn't load Zend_* classes + * from test tree */ +require_once("Zend/Service/Nirvanix/FunctionalTestCase.php"); /** * @category Zend diff --git a/tests/Zend/Service/StrikeIron/StrikeIronTest.php b/tests/Zend/Service/StrikeIron/StrikeIronTest.php index 779a2c0bef9..f458e5d4210 100644 --- a/tests/Zend/Service/StrikeIron/StrikeIronTest.php +++ b/tests/Zend/Service/StrikeIron/StrikeIronTest.php @@ -40,6 +40,7 @@ public function setUp() public function testFactoryThrowsOnBadName() { + $this->markTestIncomplete("TODO: redesign tests that throw exceptions"); try { $this->strikeIron->getService(array('class' => 'BadServiceNameHere')); $this->fail(); diff --git a/tests/Zend/Service/Technorati/AuthorTest.php b/tests/Zend/Service/Technorati/AuthorTest.php index 5cb10b24661..b3f1e413fa7 100644 --- a/tests/Zend/Service/Technorati/AuthorTest.php +++ b/tests/Zend/Service/Technorati/AuthorTest.php @@ -19,15 +19,11 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ - /** - * Test helper + * @todo: temporary fix because test autoloader doesn't load Zend_* classes + * from test tree */ - -/** - * @see Zend_Service_Technorati_Author - */ - +require_once("Zend/Service/Technorati/TestCase.php"); /** * @category Zend diff --git a/tests/Zend/Service/Technorati/TestCase.php b/tests/Zend/Service/Technorati/TestCase.php index 95145662051..f3065c198e1 100644 --- a/tests/Zend/Service/Technorati/TestCase.php +++ b/tests/Zend/Service/Technorati/TestCase.php @@ -19,16 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ - -/** - * Test helper - */ - -/** - * Exclude from code coverage report - */ -PHPUnit_Util_Filter::addFileToFilter(__FILE__); - /** * Patch for default timezone in PHP >= 5.1.0 */ @@ -36,11 +26,6 @@ date_default_timezone_set(@date_default_timezone_get()); } -/** - * @see Zend_Service_Technorati - */ - - /** * @category Zend * @package Zend_Service_Technorati diff --git a/tests/Zend/Service/Twitter/AllTests.php b/tests/Zend/Service/Twitter/AllTests.php index a149782cb5a..7e8ebca178c 100644 --- a/tests/Zend/Service/Twitter/AllTests.php +++ b/tests/Zend/Service/Twitter/AllTests.php @@ -19,15 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -require_once dirname(dirname(dirname(__DIR__))) . DIRECTORY_SEPARATOR . 'TestHelper.php'; - -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_Twitter_AllTests::main'); -} - -require_once 'Zend/Service/Twitter/TwitterTest.php'; -require_once 'Zend/Service/Twitter/TwitterSearchTest.php'; - /** * @category Zend * @package Zend_Service_Twitter @@ -39,16 +30,6 @@ */ class Zend_Service_Twitter_AllTests { - /** - * Runs this test suite - * - * @return void - */ - public static function main() - { - PHPUnit_TextUI_TestRunner::run(self::suite()); - } - /** * Creates and returns this test suite * @@ -64,8 +45,3 @@ public static function suite() return $suite; } } - - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_Twitter_AllTests::main') { - Zend_Service_Twitter_AllTests::main(); -} diff --git a/tests/Zend/Service/Twitter/TwitterSearchTest.php b/tests/Zend/Service/Twitter/TwitterSearchTest.php index 563c6a0969d..82a8da47341 100644 --- a/tests/Zend/Service/Twitter/TwitterSearchTest.php +++ b/tests/Zend/Service/Twitter/TwitterSearchTest.php @@ -19,24 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_Twitter_TwitterSearchTest::main'); -} - -/** - * Test helper - */ -require_once __DIR__ . '/../../../TestHelper.php'; - -/** Zend_Service_Twitter_Search */ -require_once 'Zend/Service/Twitter/Search.php'; - -/** Zend_Http_Client */ -require_once 'Zend/Http/Client.php'; - -/** Zend_Http_Client_Adapter_Test */ -require_once 'Zend/Http/Client/Adapter/Test.php'; - /** * @category Zend * @package Zend_Service_Twitter @@ -48,17 +30,6 @@ */ class Zend_Service_Twitter_TwitterSearchTest extends PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite(__CLASS__); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Sets up the fixture, for example, open a network connection. * This method is called before a test is executed. @@ -178,7 +149,3 @@ public function testAtomSearchShowUserReturnsObject() } } - -if (PHPUnit_MAIN_METHOD == 'Zend_Service_TwitterSearchTest::main') { - Zend_Service_TwitterSearchTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/BlobStorageSharedAccessTest.php b/tests/Zend/Service/WindowsAzure/BlobStorageSharedAccessTest.php index 0af08d49a24..672d8e149a8 100644 --- a/tests/Zend/Service/WindowsAzure/BlobStorageSharedAccessTest.php +++ b/tests/Zend/Service/WindowsAzure/BlobStorageSharedAccessTest.php @@ -19,10 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Storage_Blob */ @@ -31,41 +27,31 @@ * @see Zend_Service_WindowsAzure_Credentials_SharedAccessSignature */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_BlobStorageSharedAccessTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Service_WindowsAzure_BlobStorageSharedAccessTest extends PHPUnit_Framework_TestCase { static $path; - + public function __construct() { self::$path = __DIR__.'/_files/'; } - - public static function main() - { - if (TESTS_ZEND_SERVICE_WINDOWSAZURE_BLOB_RUNTESTS) { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_BlobStorageSharedAccessTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - } - + /** * Test setup */ protected function setUp() { } - + /** * Test teardown */ @@ -93,14 +79,14 @@ protected function createStorageInstance() new Zend_Service_WindowsAzure_Credentials_SharedAccessSignature(TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_ACCOUNT_DEV, TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_KEY_DEV, true) ); } - + if (TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_USEPROXY) { $storageClient->setProxy(TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_USEPROXY, TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_PROXY, TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_PROXY_PORT, TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_PROXY_CREDENTIALS); } return $storageClient; } - + protected function createAdministrativeStorageInstance() { $storageClient = null; @@ -109,22 +95,22 @@ protected function createAdministrativeStorageInstance() } else { $storageClient = new Zend_Service_WindowsAzure_Storage_Blob(TESTS_ZEND_SERVICE_WINDOWSAZURE_BLOB_HOST_DEV, TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_ACCOUNT_DEV, TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_KEY_DEV, true, Zend_Service_WindowsAzure_RetryPolicy_AbstractRetryPolicy::retryN(10, 250)); } - + if (TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_USEPROXY) { $storageClient->setProxy(TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_USEPROXY, TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_PROXY, TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_PROXY_PORT, TESTS_ZEND_SERVICE_WINDOWSAZURE_STORAGE_PROXY_CREDENTIALS); } return $storageClient; } - + protected static $uniqId = 0; - + protected function generateName() { self::$uniqId++; return TESTS_ZEND_SERVICE_WINDOWSAZURE_BLOBSA_CONTAINER_PREFIX . self::$uniqId; } - + /** * Test shared access, only write */ @@ -132,11 +118,11 @@ public function testSharedAccess_OnlyWrite() { if (TESTS_ZEND_SERVICE_WINDOWSAZURE_BLOB_RUNTESTS) { $containerName = $this->generateName(); - + // Account owner performs this part $administrativeStorageClient = $this->createAdministrativeStorageInstance(); $administrativeStorageClient->createContainer($containerName); - + $sharedAccessUrl = $administrativeStorageClient->generateSharedAccessUrl( $containerName, '', @@ -146,7 +132,7 @@ public function testSharedAccess_OnlyWrite() $administrativeStorageClient->isoDate(time() + 3000) ); - + // Reduced permissions user performs this part $storageClient = $this->createStorageInstance(); $credentials = $storageClient->getCredentials(); @@ -155,12 +141,12 @@ public function testSharedAccess_OnlyWrite() )); $result = $storageClient->putBlob($containerName, 'images/WindowsAzure.gif', self::$path . 'WindowsAzure.gif'); - + $this->assertEquals($containerName, $result->Container); $this->assertEquals('images/WindowsAzure.gif', $result->Name); - - - + + + // Now make sure reduced permissions user can not view the uploaded blob $exceptionThrown = false; try { @@ -171,7 +157,7 @@ public function testSharedAccess_OnlyWrite() $this->assertTrue($exceptionThrown); } } - + /** * Test different accounts */ @@ -179,11 +165,11 @@ public function testDifferentAccounts() { if (TESTS_ZEND_SERVICE_WINDOWSAZURE_BLOB_RUNTESTS) { $containerName = $this->generateName(); - + // Account owner performs this part $administrativeStorageClient = $this->createAdministrativeStorageInstance(); $administrativeStorageClient->createContainer($containerName); - + $sharedAccessUrl1 = $administrativeStorageClient->generateSharedAccessUrl( $containerName, '', @@ -194,7 +180,7 @@ public function testDifferentAccounts() ); $sharedAccessUrl2 = str_replace($administrativeStorageClient->getAccountName(), 'bogusaccount', $sharedAccessUrl1); - + // Reduced permissions user performs this part and should fail, // because different accounts have been used $storageClient = $this->createStorageInstance(); @@ -213,8 +199,3 @@ public function testDifferentAccounts() } } } - -// Call Zend_Service_WindowsAzure_BlobStorageSharedAccessTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_BlobStorageSharedAccessTest::main") { - Zend_Service_WindowsAzure_BlobStorageSharedAccessTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/BlobStorageTest.php b/tests/Zend/Service/WindowsAzure/BlobStorageTest.php index 981dbca3371..f5b59862331 100644 --- a/tests/Zend/Service/WindowsAzure/BlobStorageTest.php +++ b/tests/Zend/Service/WindowsAzure/BlobStorageTest.php @@ -20,22 +20,16 @@ */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Storage_Blob */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_BlobStorageTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -48,12 +42,6 @@ public function __construct() self::$path = __DIR__.'/_files/'; } - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_BlobStorageTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test setup */ @@ -477,8 +465,3 @@ private function _createLargeFile() return $fileName; } } - -// Call Zend_Service_WindowsAzure_BlobStorageTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_BlobStorageTest::main") { - Zend_Service_WindowsAzure_BlobStorageTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/BlobStreamTest.php b/tests/Zend/Service/WindowsAzure/BlobStreamTest.php index 78a7c656f6f..edfa8952ea3 100644 --- a/tests/Zend/Service/WindowsAzure/BlobStreamTest.php +++ b/tests/Zend/Service/WindowsAzure/BlobStreamTest.php @@ -19,22 +19,16 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Storage_Blob */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_BlobStreamTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -47,14 +41,6 @@ public function __construct() self::$path = __DIR__.'/_files/'; } - public static function main() - { - if (TESTS_ZEND_SERVICE_WINDOWSAZURE_BLOB_RUNTESTS) { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_BlobStreamTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - } - /** * Test setup */ @@ -303,8 +289,3 @@ public function testOpendir() } } } - -// Call Zend_Service_WindowsAzure_BlobStreamTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_BlobStreamTest::main") { - Zend_Service_WindowsAzure_BlobStreamTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/Credentials/SharedAccessSignatureTest.php b/tests/Zend/Service/WindowsAzure/Credentials/SharedAccessSignatureTest.php index 33eccc8c9fc..bb3a87398b2 100644 --- a/tests/Zend/Service/WindowsAzure/Credentials/SharedAccessSignatureTest.php +++ b/tests/Zend/Service/WindowsAzure/Credentials/SharedAccessSignatureTest.php @@ -19,34 +19,21 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Credentials_SharedAccessSignature */ - -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_SharedAccessSignatureCredentialsTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Service_WindowsAzure_Credentials_SharedAccessSignatureTest extends PHPUnit_Framework_TestCase { - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_Credentials_SharedAccessSignatureTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test signing a container */ @@ -133,8 +120,3 @@ public function testSignRequestUrl() $this->assertEquals('http://blob.core.windows.net/myaccount/pictures/blob.txt?comp=metadata&' . $queryString, $result); } } - -// Call Zend_Service_WindowsAzure_Credentials_SharedAccessSignatureTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_Credentials_SharedAccessSignatureTest::main") { - Zend_Service_WindowsAzure_Credentials_SharedAccessSignatureTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/Credentials/SharedKeyLiteTest.php b/tests/Zend/Service/WindowsAzure/Credentials/SharedKeyLiteTest.php index 627d774a427..88f5791f4a5 100644 --- a/tests/Zend/Service/WindowsAzure/Credentials/SharedKeyLiteTest.php +++ b/tests/Zend/Service/WindowsAzure/Credentials/SharedKeyLiteTest.php @@ -19,33 +19,21 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Credentials_SharedKeyLite */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_SharedKeyLiteCredentialsTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Service_WindowsAzure_Credentials_SharedKeyLiteTest extends PHPUnit_Framework_TestCase { - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_Credentials_SharedKeyLiteTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test signing for devstore with root path */ @@ -160,8 +148,3 @@ public function testSignForProductionWithQueryString() $this->assertEquals("SharedKeyLite testing:vZdOn/j0gW5FG0kAUG9NhSBO9eBjZqfe6RwALPYUtqU=", $signedHeaders["Authorization"]); } } - -// Call Zend_Service_WindowsAzure_Credentials_SharedKeyLiteTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_Credentials_SharedKeyLiteTest::main") { - Zend_Service_WindowsAzure_Credentials_SharedKeyLiteTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/Credentials/SharedKeyTest.php b/tests/Zend/Service/WindowsAzure/Credentials/SharedKeyTest.php index 260a71d914d..09a3c1ed523 100644 --- a/tests/Zend/Service/WindowsAzure/Credentials/SharedKeyTest.php +++ b/tests/Zend/Service/WindowsAzure/Credentials/SharedKeyTest.php @@ -19,31 +19,19 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_SharedKeyCredentialsTest::main'); -} - /** Zend_Service_WindowsAzure_Credentials_SharedKey */ /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Service_WindowsAzure_Credentials_SharedKeyTest extends PHPUnit_Framework_TestCase { - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_Credentials_SharedKeyTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test signing for devstore with root path */ @@ -158,8 +146,3 @@ public function testSignForProductionWithQueryString() $this->assertEquals("SharedKey testing:TEYBENKs+6laykL+zCxlIbUT9v019rtMWECYwgP/OuU=", $signedHeaders["Authorization"]); } } - -// Call Zend_Service_WindowsAzure_Credentials_SharedKeyTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_Credentials_SharedKeyTest::main") { - Zend_Service_WindowsAzure_Credentials_SharedKeyTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/DynamicTableEntityTest.php b/tests/Zend/Service/WindowsAzure/DynamicTableEntityTest.php index d80d1b8e2a8..b86cc348e57 100644 --- a/tests/Zend/Service/WindowsAzure/DynamicTableEntityTest.php +++ b/tests/Zend/Service/WindowsAzure/DynamicTableEntityTest.php @@ -19,34 +19,22 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Storage_DynamicTableEntity */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_DynamicTableEntityTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Service_WindowsAzure_DynamicTableEntityTest extends PHPUnit_Framework_TestCase { - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_DynamicTableEntityTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test constructor */ @@ -104,8 +92,3 @@ public function testSetAzureValues() $this->assertEquals(true, $target->Visible); } } - -// Call Zend_Service_WindowsAzure_DynamicTableEntityTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_DynamicTableEntityTest::main") { - Zend_Service_WindowsAzure_DynamicTableEntityTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/QueueStorageTest.php b/tests/Zend/Service/WindowsAzure/QueueStorageTest.php index 03b46f95c8b..99b70643829 100644 --- a/tests/Zend/Service/WindowsAzure/QueueStorageTest.php +++ b/tests/Zend/Service/WindowsAzure/QueueStorageTest.php @@ -19,33 +19,21 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Storage_Queue */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_QueueStorageTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Service_WindowsAzure_QueueStorageTest extends PHPUnit_Framework_TestCase { - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_QueueStorageTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test setup */ @@ -295,8 +283,3 @@ public function testDeleteMessage() $this->assertEquals(2, count($messages2)); } } - -// Call Zend_Service_WindowsAzure_QueueStorageTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_QueueStorageTest::main") { - Zend_Service_WindowsAzure_QueueStorageTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/RetryPolicyTest.php b/tests/Zend/Service/WindowsAzure/RetryPolicyTest.php index 79b74da50fe..c73265bfbc6 100644 --- a/tests/Zend/Service/WindowsAzure/RetryPolicyTest.php +++ b/tests/Zend/Service/WindowsAzure/RetryPolicyTest.php @@ -19,22 +19,16 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_RetryPolicy_AbstractRetryPolicy */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_RetryPolicyTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -53,12 +47,6 @@ class Zend_Service_WindowsAzure_RetryPolicyTest extends PHPUnit_Framework_TestCa * @var int */ protected $_exceptionCount = 0; - - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_RetryPolicyTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } /** * Test retry policy - noRetry @@ -108,8 +96,3 @@ public function _countRetriesAndThrowExceptions() return $this->_executedRetries; } } - -// Call Zend_Service_WindowsAzure_RetryPolicyTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_RetryPolicyTest::main") { - Zend_Service_WindowsAzure_RetryPolicyTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/SessionHandlerTest.php b/tests/Zend/Service/WindowsAzure/SessionHandlerTest.php index bf963070dfb..75b4896282b 100644 --- a/tests/Zend/Service/WindowsAzure/SessionHandlerTest.php +++ b/tests/Zend/Service/WindowsAzure/SessionHandlerTest.php @@ -19,10 +19,6 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_SessionHandler */ @@ -31,14 +27,12 @@ * @see Zend_Service_WindowsAzure_Storage_Table */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_SessionHandlerTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -48,12 +42,6 @@ public function __construct() { } - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_SessionHandlerTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test setup */ @@ -238,8 +226,3 @@ protected function session_id() return md5(self::$uniqId); } } - -// Call Zend_Service_WindowsAzure_SessionHandlerTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_SessionHandlerTest::main") { - Zend_Service_WindowsAzure_SessionHandlerTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/StorageTest.php b/tests/Zend/Service/WindowsAzure/StorageTest.php index de269455e72..a0b376fe61f 100644 --- a/tests/Zend/Service/WindowsAzure/StorageTest.php +++ b/tests/Zend/Service/WindowsAzure/StorageTest.php @@ -19,33 +19,21 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Storage */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_StorageTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Service_WindowsAzure_StorageTest extends PHPUnit_Framework_TestCase { - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_BlobStorageTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test constructor for devstore */ @@ -64,8 +52,3 @@ public function testConstructorForProduction() $this->assertEquals('http://testing.blob.core.windows.net', $storage->getBaseUrl()); } } - -// Call Zend_Service_WindowsAzure_StorageTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_StorageTest::main") { - Zend_Service_WindowsAzure_StorageTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/TableEntityQueryTest.php b/tests/Zend/Service/WindowsAzure/TableEntityQueryTest.php index d0cd0002e5b..641b77f9553 100644 --- a/tests/Zend/Service/WindowsAzure/TableEntityQueryTest.php +++ b/tests/Zend/Service/WindowsAzure/TableEntityQueryTest.php @@ -19,33 +19,21 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Storage_TableEntityQuery */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_TableEntityQueryTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Service_WindowsAzure_TableEntityQueryTest extends PHPUnit_Framework_TestCase { - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_TableEntityQueryTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test all records query */ @@ -178,8 +166,3 @@ public function testWhereMultipleQuery() $this->assertEquals('MyTable()?$filter=Name eq \'Maarten\' and Visible eq true', $target->__toString()); } } - -// Call Zend_Service_WindowsAzure_TableEntityQueryTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_TableEntityQueryTest::main") { - Zend_Service_WindowsAzure_TableEntityQueryTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/TableEntityTest.php b/tests/Zend/Service/WindowsAzure/TableEntityTest.php index dc50695004f..bda1d4e4ea9 100644 --- a/tests/Zend/Service/WindowsAzure/TableEntityTest.php +++ b/tests/Zend/Service/WindowsAzure/TableEntityTest.php @@ -19,33 +19,21 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Storage_TableEntity */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_TableEntityTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Service_WindowsAzure_TableEntityTest extends PHPUnit_Framework_TestCase { - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_TableEntityTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test constructor */ @@ -144,8 +132,3 @@ class TSETTest_TestEntity extends Zend_Service_WindowsAzure_Storage_TableEntity */ public $Visible = false; } - -// Call Zend_Service_WindowsAzure_TableEntityTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_TableEntityTest::main") { - Zend_Service_WindowsAzure_TableEntityTest::main(); -} diff --git a/tests/Zend/Service/WindowsAzure/TableStorageTest.php b/tests/Zend/Service/WindowsAzure/TableStorageTest.php index 0028e16a661..d65119acd27 100644 --- a/tests/Zend/Service/WindowsAzure/TableStorageTest.php +++ b/tests/Zend/Service/WindowsAzure/TableStorageTest.php @@ -19,22 +19,16 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ -/** - * Test helpers - */ - /** * @see Zend_Service_WindowsAzure_Storage_Table */ -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Service_WindowsAzure_TableStorageTest::main'); -} - /** * @category Zend * @package Zend_Service_WindowsAzure * @subpackage UnitTests + * @group Zend_Service + * @group Zend_Service_WindowsAzure * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -44,12 +38,6 @@ public function __construct() { } - public static function main() - { - $suite = new PHPUnit_Framework_TestSuite("Zend_Service_WindowsAzure_TableStorageTest"); - $result = PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Test setup */ @@ -716,8 +704,3 @@ class TSTest_TestEntity extends Zend_Service_WindowsAzure_Storage_TableEntity */ public $Visible = false; } - -// Call Zend_Service_WindowsAzure_TableStorageTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Service_WindowsAzure_TableStorageTest::main") { - Zend_Service_WindowsAzure_TableStorageTest::main(); -} diff --git a/tests/Zend/Service/Yahoo/OfflineTest.php b/tests/Zend/Service/Yahoo/OfflineTest.php index 6754e20a2fe..1bd3041f86b 100644 --- a/tests/Zend/Service/Yahoo/OfflineTest.php +++ b/tests/Zend/Service/Yahoo/OfflineTest.php @@ -33,11 +33,11 @@ */ /** - * @see Zend_Http_Client_Adapter_Socket + * @see Zend\Http\Client\Adapter\Socket */ /** - * @see Zend_Http_Client_Adapter_Test + * @see Zend\Http\Client\Adapter\Test */ /** @@ -85,9 +85,9 @@ public function setUp() { $this->_yahoo = new Zend_Service_Yahoo(constant('TESTS_ZEND_SERVICE_YAHOO_ONLINE_APPID')); - $this->_httpClientAdapterSocket = new Zend_Http_Client_Adapter_Socket(); + $this->_httpClientAdapterSocket = new Zend\Http\Client\Adapter\Socket(); - $this->_httpClientAdapterTest = new Zend_Http_Client_Adapter_Test(); + $this->_httpClientAdapterTest = new Zend\Http\Client\Adapter\Test(); } /** diff --git a/tests/Zend/Session/ContainerTest.php b/tests/Zend/Session/ContainerTest.php index b5c60571a92..7fa20bb7115 100644 --- a/tests/Zend/Session/ContainerTest.php +++ b/tests/Zend/Session/ContainerTest.php @@ -1,4 +1,24 @@ assertEquals($compareString, $output); } } - -// Call Zend_Text_FigletTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Text_FigletTest::main") { - \Zend_Text_FigletTest::main(); -} diff --git a/tests/Zend/Text/MultiByteTest.php b/tests/Zend/Text/MultiByteTest.php index 35ac0886c99..4a6d3c31a8d 100644 --- a/tests/Zend/Text/MultiByteTest.php +++ b/tests/Zend/Text/MultiByteTest.php @@ -35,7 +35,6 @@ */ class MultiByteTest extends \PHPUnit_Framework_TestCase { - /** * Standard cut tests */ diff --git a/tests/Zend/Text/TableTest.php b/tests/Zend/Text/TableTest.php index f75a207a9c4..71f1179cbd0 100644 --- a/tests/Zend/Text/TableTest.php +++ b/tests/Zend/Text/TableTest.php @@ -36,7 +36,6 @@ */ class TableTest extends \PHPUnit_Framework_TestCase { - public function tearDown() { Table\Table::setInputCharset('utf-8'); @@ -429,8 +428,3 @@ public function testDecoratorAscii() $this->assertEquals($chars, '+++-++++|++'); } } - -// Call Zend_Text_TableTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Text_TableTest::main") { - \Zend_Text_TableTest::main(); -} diff --git a/tests/Zend/Tool/Framework/Client/RequestTest.php b/tests/Zend/Tool/Framework/Client/RequestTest.php index d5a89d157f3..cb115a20ff3 100644 --- a/tests/Zend/Tool/Framework/Client/RequestTest.php +++ b/tests/Zend/Tool/Framework/Client/RequestTest.php @@ -24,14 +24,6 @@ */ namespace ZendTest\Tool\Framework\Client; -/** - * @see TestHelper.php - */ - -/** - * @see Zend_Tool_Framework_Client_Request - */ - /** * @category Zend * @package Zend_Tool diff --git a/tests/Zend/Translator/Adapter/ArrayTest.php b/tests/Zend/Translator/Adapter/ArrayTest.php index 1c16a11b880..0a94a537dc5 100644 --- a/tests/Zend/Translator/Adapter/ArrayTest.php +++ b/tests/Zend/Translator/Adapter/ArrayTest.php @@ -29,11 +29,6 @@ use Zend\Cache; use Zend\Cache\Frontend; -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Translate_Adapter_ArrayTest::main'); -} - - /** * Zend_Translate_Adapter_Array */ @@ -340,8 +335,3 @@ public function errorHandlerIgnore($errno, $errstr, $errfile, $errline, array $e $this->_errorOccurred = true; } } - -// Call Zend_Translate_Adapter_ArrayTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Translate_Adapter_ArrayTest::main") { - \Zend_Translate_Adapter_ArrayTest::main(); -} diff --git a/tests/Zend/Translator/Adapter/GettextTest.php b/tests/Zend/Translator/Adapter/GettextTest.php index 187dabcf634..f226a7c1ddb 100644 --- a/tests/Zend/Translator/Adapter/GettextTest.php +++ b/tests/Zend/Translator/Adapter/GettextTest.php @@ -37,18 +37,6 @@ */ class GettextTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Translate_Adapter_GettextTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - Adapter\Gettext::removeCache(); - } - public function setUp() { if (Adapter\Gettext::hasCache()) { diff --git a/tests/Zend/Translator/Adapter/QtTest.php b/tests/Zend/Translator/Adapter/QtTest.php index 3533887e05d..14cf6a16a82 100644 --- a/tests/Zend/Translator/Adapter/QtTest.php +++ b/tests/Zend/Translator/Adapter/QtTest.php @@ -31,10 +31,6 @@ * Zend_Translate_Adapter_Qt */ -/** - * PHPUnit test case - */ - /** * @category Zend * @package Zend_Translate @@ -45,17 +41,6 @@ */ class QtTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Translate_Adapter_QtTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - public function testCreate() { $adapter = new Adapter\Qt(__DIR__ . '/_files/translation_en.ts'); diff --git a/tests/Zend/Uri/UrlTest.php b/tests/Zend/Uri/UrlTest.php index 79aefb289b4..4020fc4c402 100644 --- a/tests/Zend/Uri/UrlTest.php +++ b/tests/Zend/Uri/UrlTest.php @@ -1,8 +1,36 @@ assertEquals(array('12345' => 'crc32', '12344' => 'crc32', '12321' => 'crc32', '12121' => 'crc32'), $validator->getCrc32()); } } - -// Call Zend_Validate_File_Crc32Test::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Validate_File_Crc32Test::main") { - \Zend_Validate_File_Crc32Test::main(); -} diff --git a/tests/Zend/Validator/File/ExcludeExtensionTest.php b/tests/Zend/Validator/File/ExcludeExtensionTest.php index 5a4bdc411c0..6ddabfa0a61 100644 --- a/tests/Zend/Validator/File/ExcludeExtensionTest.php +++ b/tests/Zend/Validator/File/ExcludeExtensionTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,45 +22,25 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; -// Call Zend_Validate_File_ExcludeExtensionTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Validate_File_ExcludeExtensionTest::main"); -} - /** - * Test helper - */ - -/** - * @see Zend_Validate_File_ExcludeExtension + * @see Zend_Validator_File_ExcludeExtension */ /** * ExcludeExtension testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class ExcludeExtensionTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Validate_File_ExcludeExtensionTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Ensures that the validator follows expected behavior * @@ -192,8 +172,3 @@ public function testAddExtension() $this->assertEquals(array('mo', 'gif', 'jpg', 'to', 'zip', 'ti'), $validator->getExtension()); } } - -// Call Zend_Validate_File_ExcludeExtensionTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Validate_File_ExcludeExtensionTest::main") { - \Zend_Validate_File_ExtensionTest::main(); -} diff --git a/tests/Zend/Validator/File/ExcludeMimeTypeTest.php b/tests/Zend/Validator/File/ExcludeMimeTypeTest.php index 2f422a750a2..6d219cfd891 100644 --- a/tests/Zend/Validator/File/ExcludeMimeTypeTest.php +++ b/tests/Zend/Validator/File/ExcludeMimeTypeTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,18 +22,18 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; /** * ExcludeMimeType testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class ExcludeMimeTypeTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/File/ExistsTest.php b/tests/Zend/Validator/File/ExistsTest.php index afe284be3b7..b5c7605a7d0 100644 --- a/tests/Zend/Validator/File/ExistsTest.php +++ b/tests/Zend/Validator/File/ExistsTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,45 +22,25 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; -// Call Zend_Validate_File_ExistsTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Validate_File_ExistsTest::main"); -} - /** - * Test helper - */ - -/** - * @see Zend_Validate_File_Size + * @see Zend_Validator_File_Size */ /** * Exists testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class ExistsTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Validate_File_ExistsTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Ensures that the validator follows expected behavior * @@ -208,7 +188,3 @@ public function testAddDirectory() } } -// Call Zend_Validate_File_ExistsTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Validate_File_ExistsTest::main") { - \Zend_Validate_File_ExistsTest::main(); -} diff --git a/tests/Zend/Validator/File/ExtensionTest.php b/tests/Zend/Validator/File/ExtensionTest.php index 231539288a8..d26d73977fd 100644 --- a/tests/Zend/Validator/File/ExtensionTest.php +++ b/tests/Zend/Validator/File/ExtensionTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,45 +22,25 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; -// Call Zend_Validate_File_ExtensionTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Validate_File_ExtensionTest::main"); -} - /** - * Test helper - */ - -/** - * @see Zend_Validate_File_Extension + * @see Zend_Validator_File_Extension */ /** * Extension testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class ExtensionTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Validate_File_ExtensionTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Ensures that the validator follows expected behavior * @@ -192,8 +172,3 @@ public function testAddExtension() $this->assertEquals(array('mo', 'gif', 'jpg', 'to', 'zip', 'ti'), $validator->getExtension()); } } - -// Call Zend_Validate_File_ExtensionTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Validate_File_ExtensionTest::main") { - \Zend_Validate_File_ExtensionTest::main(); -} diff --git a/tests/Zend/Validator/File/FilesSizeTest.php b/tests/Zend/Validator/File/FilesSizeTest.php index 993ef925c4a..e654dd83f4f 100644 --- a/tests/Zend/Validator/File/FilesSizeTest.php +++ b/tests/Zend/Validator/File/FilesSizeTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,22 +22,20 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; use Zend\Validator; /** * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class FilesSizeTest extends \PHPUnit_Framework_TestCase { - - public function setUp() { $this->multipleOptionsDetected = false; diff --git a/tests/Zend/Validator/File/HashTest.php b/tests/Zend/Validator/File/HashTest.php index 927743df71f..f128a8d1e02 100644 --- a/tests/Zend/Validator/File/HashTest.php +++ b/tests/Zend/Validator/File/HashTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,45 +22,25 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; -// Call Zend_Validate_File_HashTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Validate_File_HashTest::main"); -} - /** - * Test helper - */ - -/** - * @see Zend_Validate_File_Hash + * @see Zend_Validator_File_Hash */ /** * Hash testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class HashTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Validate_File_HashTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Ensures that the validator follows expected behavior * @@ -181,8 +161,3 @@ public function testAddHash() $this->assertEquals(array('12345' => 'crc32', '12344' => 'crc32', '12321' => 'crc32', '12121' => 'crc32'), $validator->getHash()); } } - -// Call Zend_Validate_File_HashTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Validate_File_HashTest::main") { - \Zend_Validate_File_HashTest::main(); -} diff --git a/tests/Zend/Validator/File/ImageSizeTest.php b/tests/Zend/Validator/File/ImageSizeTest.php index 24b2bce30ce..c2f04970632 100644 --- a/tests/Zend/Validator/File/ImageSizeTest.php +++ b/tests/Zend/Validator/File/ImageSizeTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,22 +22,21 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; use Zend\Validator; /** * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class ImageSizeTest extends \PHPUnit_Framework_TestCase { - /** * Ensures that the validator follows expected behavior * diff --git a/tests/Zend/Validator/File/IsCompressedTest.php b/tests/Zend/Validator/File/IsCompressedTest.php index dbf720dfc07..06b35ba180e 100644 --- a/tests/Zend/Validator/File/IsCompressedTest.php +++ b/tests/Zend/Validator/File/IsCompressedTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,31 +22,22 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; -// Call Zend_Validate_File_MimeTypeTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Validate_File_IsCompressedTest::main"); -} - -/** - * Test helper - */ - /** - * @see Zend_Validate_File_IsCompressed + * @see Zend_Validator_File_IsCompressed */ /** * IsCompressed testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class IsCompressedTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/File/IsImageTest.php b/tests/Zend/Validator/File/IsImageTest.php index 7662ca30aa6..54074e6e422 100644 --- a/tests/Zend/Validator/File/IsImageTest.php +++ b/tests/Zend/Validator/File/IsImageTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,31 +22,22 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; -// Call Zend_Validate_File_IsImageTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Validate_File_IsImageTest::main"); -} - -/** - * Test helper - */ - /** - * @see Zend_Validate_File_IsImage + * @see Zend_Validator_File_IsImage */ /** * IsImage testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class IsImageTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/File/Md5Test.php b/tests/Zend/Validator/File/Md5Test.php index 3b28416d89f..8b73e303669 100644 --- a/tests/Zend/Validator/File/Md5Test.php +++ b/tests/Zend/Validator/File/Md5Test.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,45 +22,25 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; -// Call Zend_Validate_File_Md5Test::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Validate_File_Md5Test::main"); -} - /** - * Test helper - */ - -/** - * @see Zend_Validate_File_Md5 + * @see Zend_Validator_File_Md5 */ /** * Md5 testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class Md5Test extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Validate_File_Md5Test"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Ensures that the validator follows expected behavior * @@ -209,8 +189,3 @@ public function testAddHash() $this->assertEquals(array('12345' => 'md5', '12344' => 'md5', '12321' => 'md5', '12121' => 'md5'), $validator->getMd5()); } } - -// Call Zend_Validate_File_Md5Test::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Validate_File_Md5Test::main") { - \Zend_Validate_File_Md5Test::main(); -} diff --git a/tests/Zend/Validator/File/MimeTypeTest.php b/tests/Zend/Validator/File/MimeTypeTest.php index ad42d134f15..0250de0aafa 100644 --- a/tests/Zend/Validator/File/MimeTypeTest.php +++ b/tests/Zend/Validator/File/MimeTypeTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,7 +22,7 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; use Zend\Validator; @@ -30,11 +30,11 @@ * MimeType testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class MimeTypeTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/File/NotExistsTest.php b/tests/Zend/Validator/File/NotExistsTest.php index f9fb1b09f2b..3f1249e6818 100644 --- a/tests/Zend/Validator/File/NotExistsTest.php +++ b/tests/Zend/Validator/File/NotExistsTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,45 +22,25 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; -// Call Zend_Validate_File_NotExistsTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Validate_File_NotExistsTest::main"); -} - /** - * Test helper - */ - -/** - * @see Zend_Validate_File_Size + * @see Zend_Validator_File_Size */ /** * NotExists testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class NotExistsTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Validate_File_NotExistsTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Ensures that the validator follows expected behavior * @@ -207,8 +187,3 @@ public function testAddDirectory() $this->assertEquals(array('temp', 'gif', 'jpg', 'to', 'zip', 'ti'), $validator->getDirectory(true)); } } - -// Call Zend_Validate_File_NotExistsTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Validate_File_NotExistsTest::main") { - \Zend_Validate_File_NotExistsTest::main(); -} diff --git a/tests/Zend/Validator/File/Sha1Test.php b/tests/Zend/Validator/File/Sha1Test.php index 2df7f929594..e40e00871a8 100644 --- a/tests/Zend/Validator/File/Sha1Test.php +++ b/tests/Zend/Validator/File/Sha1Test.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,45 +22,25 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; -// Call Zend_Validate_File_Sha1Test::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_Validate_File_Sha1Test::main"); -} - /** - * Test helper - */ - -/** - * @see Zend_Validate_File_Sha1 + * @see Zend_Validator_File_Sha1 */ /** * Sha1 testbed * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class Sha1Test extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @return void - */ - public static function main() - { - $suite = new \PHPUnit_Framework_TestSuite("Zend_Validate_File_Sha1Test"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - /** * Ensures that the validator follows expected behavior * @@ -209,8 +189,3 @@ public function testAddHash() $this->assertEquals(array('12345' => 'sha1', '12344' => 'sha1', '12321' => 'sha1', '12121' => 'sha1'), $validator->getSha1()); } } - -// Call Zend_Validate_File_Sha1Test::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_Validate_File_Sha1Test::main") { - \Zend_Validate_File_Sha1Test::main(); -} diff --git a/tests/Zend/Validator/File/SizeTest.php b/tests/Zend/Validator/File/SizeTest.php index e1de62684b4..378e6a21dc7 100644 --- a/tests/Zend/Validator/File/SizeTest.php +++ b/tests/Zend/Validator/File/SizeTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,23 +22,20 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; use Zend\Validator; - /** * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class SizeTest extends \PHPUnit_Framework_TestCase { - - /** * Ensures that the validator follows expected behavior * diff --git a/tests/Zend/Validator/File/UploadTest.php b/tests/Zend/Validator/File/UploadTest.php index 1328263bd80..997d3a1fe49 100644 --- a/tests/Zend/Validator/File/UploadTest.php +++ b/tests/Zend/Validator/File/UploadTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,20 +22,19 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; /** * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class UploadTest extends \PHPUnit_Framework_TestCase { - /** * Ensures that the validator follows expected behavior * @@ -234,4 +233,3 @@ public function testSetFiles() $this->assertEquals($files, $validator->getFiles()); } } - diff --git a/tests/Zend/Validator/File/WordCountTest.php b/tests/Zend/Validator/File/WordCountTest.php index 92adc780d0d..fdf6f112788 100644 --- a/tests/Zend/Validator/File/WordCountTest.php +++ b/tests/Zend/Validator/File/WordCountTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,21 +22,20 @@ /** * @namespace */ -namespace ZendTest\Validate\File; +namespace ZendTest\Validator\File; use Zend\Validator\File; use Zend\Validator; /** * @category Zend - * @package Zend_Validate_File + * @package Zend_Validator_File * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class WordCountTest extends \PHPUnit_Framework_TestCase { - /** * Ensures that the validator follows expected behavior * diff --git a/tests/Zend/Validator/FloatTest.php b/tests/Zend/Validator/FloatTest.php index a4271d36788..90f096e66bb 100644 --- a/tests/Zend/Validator/FloatTest.php +++ b/tests/Zend/Validator/FloatTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -30,28 +30,28 @@ */ /** - * @see Zend_Validate_Float + * @see Zend_Validator_Float */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class FloatTest extends \PHPUnit_Framework_TestCase { /** - * Zend_Validate_Float object + * Zend_Validator_Float object * - * @var Zend_Validate_Float + * @var Zend_Validator_Float */ protected $_validator; /** - * Creates a new Zend_Validate_Float object for each test method + * Creates a new Zend_Validator_Float object for each test method * * @return void */ diff --git a/tests/Zend/Validator/GreaterThanTest.php b/tests/Zend/Validator/GreaterThanTest.php index 7f87052b0e1..ba304aac733 100644 --- a/tests/Zend/Validator/GreaterThanTest.php +++ b/tests/Zend/Validator/GreaterThanTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -30,17 +30,17 @@ */ /** - * @see Zend_Validate_GreaterThan + * @see Zend_Validator_GreaterThan */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class GreaterThanTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/HexTest.php b/tests/Zend/Validator/HexTest.php index 03a7148be02..b44c36e6af1 100644 --- a/tests/Zend/Validator/HexTest.php +++ b/tests/Zend/Validator/HexTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -29,29 +29,29 @@ */ /** - * @see Zend_Validate_Hex + * @see Zend_Validator_Hex */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class HexTest extends \PHPUnit_Framework_TestCase { /** - * Zend_Validate_Hex object + * Zend_Validator_Hex object * - * @var Zend_Validate_Hex + * @var Zend_Validator_Hex */ protected $_validator; /** - * Creates a new Zend_Validate_Hex object for each test method + * Creates a new Zend_Validator_Hex object for each test method * * @return void */ diff --git a/tests/Zend/Validator/HostnameTest.php b/tests/Zend/Validator/HostnameTest.php index 063db27a641..55b858962e4 100644 --- a/tests/Zend/Validator/HostnameTest.php +++ b/tests/Zend/Validator/HostnameTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -27,23 +27,23 @@ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class HostnameTest extends \PHPUnit_Framework_TestCase { /** * Default instance created for all test methods * - * @var Zend_Validate_Hostname + * @var Zend_Validator_Hostname */ protected $_validator; /** - * Creates a new Zend_Validate_Hostname object for each test method + * Creates a new Zend_Validator_Hostname object for each test method * * @return void */ diff --git a/tests/Zend/Validator/IbanTest.php b/tests/Zend/Validator/IbanTest.php index 006202e46ab..57f6a45c438 100644 --- a/tests/Zend/Validator/IbanTest.php +++ b/tests/Zend/Validator/IbanTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -25,14 +25,13 @@ namespace ZendTest\Validator; use Zend\Validator; - /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class IbanTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/IdenticalTest.php b/tests/Zend/Validator/IdenticalTest.php index 368c0cd671f..e3fb17c3fa4 100644 --- a/tests/Zend/Validator/IdenticalTest.php +++ b/tests/Zend/Validator/IdenticalTest.php @@ -25,24 +25,18 @@ namespace ZendTest\Validator; use Zend\Validator; -// Call Zend_Validate_IdenticalTest::main() if this source file is executed directly. -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Validate_IdenticalTest::main'); -} - - -/** Zend_Validate_Identical */ +/** Zend_Validator_Identical */ /** - * Zend_Validate_Identical + * Zend_Validator_Identical * * @category Zend * @package Zend * @subpackage UnitTests - * @uses Zend_Validate_Identical + * @uses Zend_Validator_Identical * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class IdenticalTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/InArrayTest.php b/tests/Zend/Validator/InArrayTest.php index 9f03d4f71b2..39a794c5d53 100644 --- a/tests/Zend/Validator/InArrayTest.php +++ b/tests/Zend/Validator/InArrayTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -30,17 +30,17 @@ */ /** - * @see Zend_Validate_InArray + * @see Zend_Validator_InArray */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class InArrayTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/IntTest.php b/tests/Zend/Validator/IntTest.php index e9af6296c81..c3108c0c2b2 100644 --- a/tests/Zend/Validator/IntTest.php +++ b/tests/Zend/Validator/IntTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -31,29 +31,29 @@ */ /** - * @see Zend_Validate_Int + * @see Zend_Validator_Int */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class IntTest extends \PHPUnit_Framework_TestCase { /** - * Zend_Validate_Int object + * Zend_Validator_Int object * - * @var Zend_Validate_Int + * @var Zend_Validator_Int */ protected $_validator; /** - * Creates a new Zend_Validate_Int object for each test method + * Creates a new Zend_Validator_Int object for each test method * * @return void */ diff --git a/tests/Zend/Validator/IpTest.php b/tests/Zend/Validator/IpTest.php index 1a84d5c69f3..90d5c70f094 100644 --- a/tests/Zend/Validator/IpTest.php +++ b/tests/Zend/Validator/IpTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -29,28 +29,28 @@ */ /** - * @see Zend_Validate_Ip + * @see Zend_Validator_Ip */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class IpTest extends \PHPUnit_Framework_TestCase { /** - * Zend_Validate_Ip object + * Zend_Validator_Ip object * - * @var Zend_Validate_Ip + * @var Zend_Validator_Ip */ protected $_validator; /** - * Creates a new Zend_Validate_Ip object for each test method + * Creates a new Zend_Validator_Ip object for each test method * * @return void */ diff --git a/tests/Zend/Validator/IsbnTest.php b/tests/Zend/Validator/IsbnTest.php index bf36513dee5..0217a2bb89e 100644 --- a/tests/Zend/Validator/IsbnTest.php +++ b/tests/Zend/Validator/IsbnTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ @@ -27,8 +27,9 @@ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests + * @group Zend_Validator * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ diff --git a/tests/Zend/Validator/LessThanTest.php b/tests/Zend/Validator/LessThanTest.php index 9b44c6b87e5..17b33f15814 100644 --- a/tests/Zend/Validator/LessThanTest.php +++ b/tests/Zend/Validator/LessThanTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -30,17 +30,17 @@ */ /** - * @see Zend_Validate_LessThan + * @see Zend_Validator_LessThan */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class LessThanTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/MessageTest.php b/tests/Zend/Validator/MessageTest.php index d220e517461..c5ef4762b55 100644 --- a/tests/Zend/Validator/MessageTest.php +++ b/tests/Zend/Validator/MessageTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -27,23 +27,23 @@ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class MessageTest extends \PHPUnit_Framework_TestCase { /** * Default instance created for all test methods * - * @var Zend_Validate_StringLength + * @var Zend_Validator_StringLength */ protected $_validator; /** - * Creates a new Zend_Validate_StringLength object for each test method + * Creates a new Zend_Validator_StringLength object for each test method * * @return void */ diff --git a/tests/Zend/Validator/NotEmptyTest.php b/tests/Zend/Validator/NotEmptyTest.php index 43c23d09568..1d171367d8e 100644 --- a/tests/Zend/Validator/NotEmptyTest.php +++ b/tests/Zend/Validator/NotEmptyTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -27,23 +27,23 @@ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class NotEmptyTest extends \PHPUnit_Framework_TestCase { /** - * Zend_Validate_NotEmpty object + * Zend_Validator_NotEmpty object * - * @var Zend_Validate_NotEmpty + * @var Zend_Validator_NotEmpty */ protected $_validator; /** - * Creates a new Zend_Validate_NotEmpty object for each test method + * Creates a new Zend_Validator_NotEmpty object for each test method * * @return void */ diff --git a/tests/Zend/Validator/PostCodeTest.php b/tests/Zend/Validator/PostCodeTest.php index 89468920f27..cea5ebf31ad 100644 --- a/tests/Zend/Validator/PostCodeTest.php +++ b/tests/Zend/Validator/PostCodeTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -25,38 +25,29 @@ namespace ZendTest\Validator; use Zend\Validator; -if (!defined('PHPUnit_MAIN_METHOD')) { - define('PHPUnit_MAIN_METHOD', 'Zend_Validate_PostCodeTest::main'); -} - -/** - * Test helper - */ - /** - * @see Zend_Validate_PostCode + * @see Zend_Validator_PostCode */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class PostCodeTest extends \PHPUnit_Framework_TestCase { /** - * Zend_Validate_PostCode object + * Zend_Validator_PostCode object * - * @var Zend_Validate_PostCode + * @var Zend_Validator_PostCode */ protected $_validator; - /** - * Creates a new Zend_Validate_PostCode object for each test method + * Creates a new Zend\Validator\PostCode object for each test method * * @return void */ diff --git a/tests/Zend/Validator/RegexTest.php b/tests/Zend/Validator/RegexTest.php index f148b5606ee..b615d9df18f 100644 --- a/tests/Zend/Validator/RegexTest.php +++ b/tests/Zend/Validator/RegexTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -30,17 +30,17 @@ */ /** - * @see Zend_Validate_Regex + * @see Zend_Validator_Regex */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class RegexTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/Sitemap/ChangefreqTest.php b/tests/Zend/Validator/Sitemap/ChangefreqTest.php index 264875051e2..d13074fd199 100644 --- a/tests/Zend/Validator/Sitemap/ChangefreqTest.php +++ b/tests/Zend/Validator/Sitemap/ChangefreqTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -22,24 +22,24 @@ /** * @namespace */ -namespace ZendTest\Validate\Sitemap; +namespace ZendTest\Validator\Sitemap; /** - * Tests Zym_Validate_Sitemap_Changefreq + * Tests Zym_Validator_Sitemap_Changefreq * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class ChangefreqTest extends \PHPUnit_Framework_TestCase { /** * Validator * - * @var Zend_Validate_Sitemap_Changefreq + * @var Zend_Validator_Sitemap_Changefreq */ protected $_validator; diff --git a/tests/Zend/Validator/Sitemap/LastmodTest.php b/tests/Zend/Validator/Sitemap/LastmodTest.php index 771730d9624..9f7b0d6a633 100644 --- a/tests/Zend/Validator/Sitemap/LastmodTest.php +++ b/tests/Zend/Validator/Sitemap/LastmodTest.php @@ -22,24 +22,24 @@ /** * @namespace */ -namespace ZendTest\Validate\Sitemap; +namespace ZendTest\Validator\Sitemap; /** - * Tests Zym_Validate_Sitemap_Lastmod + * Tests Zym_Validator_Sitemap_Lastmod * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class LastmodTest extends \PHPUnit_Framework_TestCase { /** * Validator * - * @var Zend_Validate_Sitemap_Lastmod + * @var Zend_Validator_Sitemap_Lastmod */ protected $_validator; diff --git a/tests/Zend/Validator/Sitemap/LocTest.php b/tests/Zend/Validator/Sitemap/LocTest.php index faa12a4c08b..94a420d12b2 100644 --- a/tests/Zend/Validator/Sitemap/LocTest.php +++ b/tests/Zend/Validator/Sitemap/LocTest.php @@ -22,24 +22,24 @@ /** * @namespace */ -namespace ZendTest\Validate\Sitemap; +namespace ZendTest\Validator\Sitemap; /** - * Tests Zend_Validate_Sitemap_Loc + * Tests Zend_Validator_Sitemap_Loc * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class LocTest extends \PHPUnit_Framework_TestCase { /** * Validator * - * @var Zend_Validate_Sitemap_Loc + * @var Zend_Validator_Sitemap_Loc */ protected $_validator; diff --git a/tests/Zend/Validator/Sitemap/PriorityTest.php b/tests/Zend/Validator/Sitemap/PriorityTest.php index f6ca6049e49..b97be9cf5d8 100644 --- a/tests/Zend/Validator/Sitemap/PriorityTest.php +++ b/tests/Zend/Validator/Sitemap/PriorityTest.php @@ -22,24 +22,24 @@ /** * @namespace */ -namespace ZendTest\Validate\Sitemap; +namespace ZendTest\Validator\Sitemap; /** - * Tests Zend_Validate_Sitemap_Priority + * Tests Zend_Validator_Sitemap_Priority * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class PriorityTest extends \PHPUnit_Framework_TestCase { /** * Validator * - * @var Zend_Validate_Sitemap_Priority + * @var Zend_Validator_Sitemap_Priority */ protected $_validator; diff --git a/tests/Zend/Validator/StaticValidatorTest.php b/tests/Zend/Validator/StaticValidatorTest.php index d0f4f494c0e..8d049e0c655 100644 --- a/tests/Zend/Validator/StaticValidatorTest.php +++ b/tests/Zend/Validator/StaticValidatorTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -32,11 +32,11 @@ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class StaticValidatorTest extends \PHPUnit_Framework_TestCase { diff --git a/tests/Zend/Validator/StringLengthTest.php b/tests/Zend/Validator/StringLengthTest.php index fad0c115766..27d2fabf122 100644 --- a/tests/Zend/Validator/StringLengthTest.php +++ b/tests/Zend/Validator/StringLengthTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -30,28 +30,28 @@ */ /** - * @see Zend_Validate_StringLength + * @see Zend_Validator_StringLength */ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ class StringLengthTest extends \PHPUnit_Framework_TestCase { /** * Default instance created for all test methods * - * @var Zend_Validate_StringLength + * @var Zend_Validator_StringLength */ protected $_validator; /** - * Creates a new Zend_Validate_StringLength object for each test method + * Creates a new Zend_Validator_StringLength object for each test method * * @return void */ diff --git a/tests/Zend/Validator/ValidateTest.php b/tests/Zend/Validator/ValidateTest.php index 4d5b8393752..3553420c463 100644 --- a/tests/Zend/Validator/ValidateTest.php +++ b/tests/Zend/Validator/ValidateTest.php @@ -13,7 +13,7 @@ * to license@zend.com so we can send you a copy immediately. * * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License @@ -28,23 +28,23 @@ /** * @category Zend - * @package Zend_Validate + * @package Zend_Validator * @subpackage UnitTests * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License - * @group Zend_Validate + * @group Zend_Validator */ -class ValidateTest extends \PHPUnit_Framework_TestCase +class ValidatorTest extends \PHPUnit_Framework_TestCase { /** - * Zend_Validate object + * Zend_Validator object * - * @var Zend_Validate + * @var Zend_Validator */ protected $_validator; /** - * Creates a new Zend_Validate object for each test method + * Creates a new Zend_Validator object for each test method * * @return void */ @@ -138,7 +138,6 @@ public function testStaticFactoryWithConstructorArguments() */ public function testStaticFactoryClassNotFound() { - $this->markTestSkipped('is() method should not try to implement its own plugin loader - refactor this'); $this->setExpectedException('Zend\Validate\Exception\RuntimeException', 'foo'); Validator\ValidatorChain::execute('1234', 'UnknownValidator'); } diff --git a/tests/Zend/View/Helper/BaseUrlTest.php b/tests/Zend/View/Helper/BaseUrlTest.php index 6a3c46e6e56..2f96f348449 100644 --- a/tests/Zend/View/Helper/BaseUrlTest.php +++ b/tests/Zend/View/Helper/BaseUrlTest.php @@ -187,8 +187,3 @@ public function testGetBaseUrlReturnsBaseUrlWithoutScriptName() $this->assertEquals('/mybar', $helper->getBaseUrl()); } } - -// Call Zend_View_Helper_BaseUrlTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == 'Zend_View_Helper_BaseUrlTest::main') { - \Zend_View_Helper_BaseUrlTest::main(); -} diff --git a/tests/Zend/View/Helper/DeclareVarsTest.php b/tests/Zend/View/Helper/DeclareVarsTest.php index bf680c5cc15..a29700bed21 100644 --- a/tests/Zend/View/Helper/DeclareVarsTest.php +++ b/tests/Zend/View/Helper/DeclareVarsTest.php @@ -24,13 +24,6 @@ */ namespace ZendTest\View\Helper; -// Call Zend_View_Helper_DeclareVarsTest::main() if this source file is executed directly. -if (!defined("PHPUnit_MAIN_METHOD")) { - define("PHPUnit_MAIN_METHOD", "Zend_View_Helper_DeclareVarsTest::main"); -} - - - /** * @category Zend * @package Zend_View @@ -42,19 +35,6 @@ */ class DeclareVarsTest extends \PHPUnit_Framework_TestCase { - /** - * Runs the test methods of this class. - * - * @access public - * @static - */ - public static function main() - { - - $suite = new \PHPUnit_Framework_TestSuite("Zend_View_Helper_DeclareVarsTest"); - $result = \PHPUnit_TextUI_TestRunner::run($suite); - } - public function setUp() { $view = new \Zend\View\View(); @@ -113,8 +93,3 @@ public function testDeclareDeclaredVars() $this->assertEquals('additionalValue', $this->view->varName5); } } - -// Call Zend_View_Helper_DeclareVarsTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_View_Helper_DeclareVarsTest::main") { - \Zend_View_Helper_DeclareVarsTest::main(); -} diff --git a/tests/Zend/View/Helper/FormCheckboxTest.php b/tests/Zend/View/Helper/FormCheckboxTest.php index d45c1d16df7..3c1b6452606 100644 --- a/tests/Zend/View/Helper/FormCheckboxTest.php +++ b/tests/Zend/View/Helper/FormCheckboxTest.php @@ -287,9 +287,3 @@ public function testIntValueIsChecked() $this->assertNotContains('checked="checked"', $test); } } - -// Call Zend_View_Helper_FormCheckboxTest::main() if this source file is executed directly. -if (PHPUnit_MAIN_METHOD == "Zend_View_Helper_FormCheckboxTest::main") { - \Zend_View_Helper_FormCheckboxTest::main(); -} - diff --git a/tests/Zend/View/Helper/FormErrorsTest.php b/tests/Zend/View/Helper/FormErrorsTest.php index 1f37399968a..ac6deb96bc4 100644 --- a/tests/Zend/View/Helper/FormErrorsTest.php +++ b/tests/Zend/View/Helper/FormErrorsTest.php @@ -156,8 +156,3 @@ public function testCanSetClassAttribute() $this->assertEquals('