Преглед на файлове

[ZF-10177] Zend_Validate:

- unified resource content

git-svn-id: http://framework.zend.com/svn/framework/standard/trunk@22668 44c647ce-9c0f-0410-b52a-842ac1e357ba
thomas преди 15 години
родител
ревизия
e8379407e9
променени са 42 файла, в които са добавени 90 реда и са изтрити 90 реда
  1. 1 1
      library/Zend/Validate/Alnum.php
  2. 1 1
      library/Zend/Validate/Alpha.php
  3. 1 1
      library/Zend/Validate/Barcode.php
  4. 1 1
      library/Zend/Validate/Callback.php
  5. 4 4
      library/Zend/Validate/CreditCard.php
  6. 1 1
      library/Zend/Validate/Date.php
  7. 2 2
      library/Zend/Validate/Db/Abstract.php
  8. 2 2
      library/Zend/Validate/Digits.php
  9. 2 2
      library/Zend/Validate/EmailAddress.php
  10. 1 1
      library/Zend/Validate/File/Crc32.php
  11. 1 1
      library/Zend/Validate/File/ExcludeExtension.php
  12. 1 1
      library/Zend/Validate/File/Extension.php
  13. 1 1
      library/Zend/Validate/File/Hash.php
  14. 1 1
      library/Zend/Validate/File/ImageSize.php
  15. 2 2
      library/Zend/Validate/File/IsCompressed.php
  16. 1 1
      library/Zend/Validate/File/IsImage.php
  17. 1 1
      library/Zend/Validate/File/Md5.php
  18. 1 1
      library/Zend/Validate/File/MimeType.php
  19. 1 1
      library/Zend/Validate/File/Sha1.php
  20. 1 1
      library/Zend/Validate/File/Size.php
  21. 1 1
      library/Zend/Validate/File/WordCount.php
  22. 1 1
      library/Zend/Validate/Float.php
  23. 1 1
      library/Zend/Validate/Hex.php
  24. 1 1
      library/Zend/Validate/Hostname.php
  25. 1 1
      library/Zend/Validate/Int.php
  26. 1 1
      library/Zend/Validate/Ip.php
  27. 1 1
      library/Zend/Validate/Isbn.php
  28. 1 1
      library/Zend/Validate/NotEmpty.php
  29. 1 1
      library/Zend/Validate/PostCode.php
  30. 1 1
      library/Zend/Validate/Regex.php
  31. 1 1
      library/Zend/Validate/Sitemap/Changefreq.php
  32. 1 1
      library/Zend/Validate/Sitemap/Lastmod.php
  33. 1 1
      library/Zend/Validate/Sitemap/Loc.php
  34. 1 1
      library/Zend/Validate/Sitemap/Priority.php
  35. 1 1
      library/Zend/Validate/StringLength.php
  36. 42 42
      resources/languages/en/Zend_Validate.php
  37. 1 1
      tests/Zend/Validate/DigitsTest.php
  38. 1 1
      tests/Zend/Validate/File/ImageSizeTest.php
  39. 1 1
      tests/Zend/Validate/Sitemap/ChangefreqTest.php
  40. 1 1
      tests/Zend/Validate/Sitemap/LastmodTest.php
  41. 1 1
      tests/Zend/Validate/Sitemap/LocTest.php
  42. 1 1
      tests/Zend/Validate/Sitemap/PriorityTest.php

+ 1 - 1
library/Zend/Validate/Alnum.php

@@ -57,7 +57,7 @@ class Zend_Validate_Alnum extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID      => "Invalid type given, value should be float, string, or integer",
+        self::INVALID      => "Invalid type given. String, integer or float expected",
         self::NOT_ALNUM    => "'%value%' contains characters which are non alphabetic and no digits",
         self::STRING_EMPTY => "'%value%' is an empty string",
     );

+ 1 - 1
library/Zend/Validate/Alpha.php

@@ -57,7 +57,7 @@ class Zend_Validate_Alpha extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID      => "Invalid type given, value should be a string",
+        self::INVALID      => "Invalid type given. String expected",
         self::NOT_ALPHA    => "'%value%' contains non alphabetic characters",
         self::STRING_EMPTY => "'%value%' is an empty string"
     );

+ 1 - 1
library/Zend/Validate/Barcode.php

@@ -46,7 +46,7 @@ class Zend_Validate_Barcode extends Zend_Validate_Abstract
         self::FAILED         => "'%value%' failed checksum validation",
         self::INVALID_CHARS  => "'%value%' contains invalid characters",
         self::INVALID_LENGTH => "'%value%' should have a length of %length% characters",
-        self::INVALID        => "Invalid type given, value should be string",
+        self::INVALID        => "Invalid type given. String expected",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/Callback.php

@@ -49,7 +49,7 @@ class Zend_Validate_Callback extends Zend_Validate_Abstract
      */
     protected $_messageTemplates = array(
         self::INVALID_VALUE    => "'%value%' is not valid",
-        self::INVALID_CALLBACK => "Failure within the callback, exception returned",
+        self::INVALID_CALLBACK => "An exception has been raised within the callback",
     );
 
     /**

+ 4 - 4
library/Zend/Validate/CreditCard.php

@@ -64,13 +64,13 @@ class Zend_Validate_CreditCard extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::CHECKSUM       => "Luhn algorithm (mod-10 checksum) failed on '%value%'",
+        self::CHECKSUM       => "'%value%' seems to contain an invalid checksum",
         self::CONTENT        => "'%value%' must contain only digits",
-        self::INVALID        => "Invalid type given, value should be a string",
+        self::INVALID        => "Invalid type given. String expected",
         self::LENGTH         => "'%value%' contains an invalid amount of digits",
         self::PREFIX         => "'%value%' is not from an allowed institute",
-        self::SERVICE        => "Validation of '%value%' has been failed by the service",
-        self::SERVICEFAILURE => "The service returned a failure while validating '%value%'",
+        self::SERVICE        => "'%value%' seems to be an invalid creditcard number",
+        self::SERVICEFAILURE => "An exception has been raised while validating '%value%'",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/Date.php

@@ -42,7 +42,7 @@ class Zend_Validate_Date extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID        => "Invalid type given, value should be string, integer, array or Zend_Date",
+        self::INVALID        => "Invalid type given. String, integer, array or Zend_Date expected",
         self::INVALID_DATE   => "'%value%' does not appear to be a valid date",
         self::FALSEFORMAT    => "'%value%' does not fit the date format '%format%'",
     );

+ 2 - 2
library/Zend/Validate/Db/Abstract.php

@@ -45,8 +45,8 @@ abstract class Zend_Validate_Db_Abstract extends Zend_Validate_Abstract
      * @var array Message templates
      */
     protected $_messageTemplates = array(
-        self::ERROR_NO_RECORD_FOUND => 'No record matching %value% was found',
-        self::ERROR_RECORD_FOUND    => 'A record matching %value% was found',
+        self::ERROR_NO_RECORD_FOUND => "No record matching '%value%' was found",
+        self::ERROR_RECORD_FOUND    => "A record matching '%value%' was found",
     );
 
     /**

+ 2 - 2
library/Zend/Validate/Digits.php

@@ -49,9 +49,9 @@ class Zend_Validate_Digits extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::NOT_DIGITS   => "'%value%' contains characters which are not digits; but only digits are allowed",
+        self::NOT_DIGITS   => "'%value%' must contain only digits",
         self::STRING_EMPTY => "'%value%' is an empty string",
-        self::INVALID      => "Invalid type given, value should be string, integer or float",
+        self::INVALID      => "Invalid type given. String, integer or float expected",
     );
 
     /**

+ 2 - 2
library/Zend/Validate/EmailAddress.php

@@ -51,11 +51,11 @@ class Zend_Validate_EmailAddress extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID            => "Invalid type given, value should be a string",
+        self::INVALID            => "Invalid type given. String expected",
         self::INVALID_FORMAT     => "'%value%' is no valid email address in the basic format local-part@hostname",
         self::INVALID_HOSTNAME   => "'%hostname%' is no valid hostname for email address '%value%'",
         self::INVALID_MX_RECORD  => "'%hostname%' does not appear to have a valid MX record for the email address '%value%'",
-        self::INVALID_SEGMENT    => "'%hostname%' is not in a routable network segment. The email address '%value%' should not be resolved from public network.",
+        self::INVALID_SEGMENT    => "'%hostname%' is not in a routable network segment. The email address '%value%' should not be resolved from public network",
         self::DOT_ATOM           => "'%localPart%' can not be matched against dot-atom format",
         self::QUOTED_STRING      => "'%localPart%' can not be matched against quoted-string format",
         self::INVALID_LOCAL_PART => "'%localPart%' is no valid local part for email address '%value%'",

+ 1 - 1
library/Zend/Validate/File/Crc32.php

@@ -47,7 +47,7 @@ class Zend_Validate_File_Crc32 extends Zend_Validate_File_Hash
     protected $_messageTemplates = array(
         self::DOES_NOT_MATCH => "File '%value%' does not match the given crc32 hashes",
         self::NOT_DETECTED   => "A crc32 hash could not be evaluated for the given file",
-        self::NOT_FOUND      => "File '%value%' could not be found",
+        self::NOT_FOUND      => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/ExcludeExtension.php

@@ -45,7 +45,7 @@ class Zend_Validate_File_ExcludeExtension extends Zend_Validate_File_Extension
      */
     protected $_messageTemplates = array(
         self::FALSE_EXTENSION => "File '%value%' has a false extension",
-        self::NOT_FOUND       => "File '%value%' could not be found",
+        self::NOT_FOUND       => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/Extension.php

@@ -45,7 +45,7 @@ class Zend_Validate_File_Extension extends Zend_Validate_Abstract
      */
     protected $_messageTemplates = array(
         self::FALSE_EXTENSION => "File '%value%' has a false extension",
-        self::NOT_FOUND       => "File '%value%' could not be found",
+        self::NOT_FOUND       => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/Hash.php

@@ -47,7 +47,7 @@ class Zend_Validate_File_Hash extends Zend_Validate_Abstract
     protected $_messageTemplates = array(
         self::DOES_NOT_MATCH => "File '%value%' does not match the given hashes",
         self::NOT_DETECTED   => "A hash could not be evaluated for the given file",
-        self::NOT_FOUND      => "File '%value%' could not be found"
+        self::NOT_FOUND      => "File '%value%' is not readable or does not exist"
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/ImageSize.php

@@ -53,7 +53,7 @@ class Zend_Validate_File_ImageSize extends Zend_Validate_Abstract
         self::HEIGHT_TOO_BIG   => "Maximum allowed height for image '%value%' should be '%maxheight%' but '%height%' detected",
         self::HEIGHT_TOO_SMALL => "Minimum expected height for image '%value%' should be '%minheight%' but '%height%' detected",
         self::NOT_DETECTED     => "The size of image '%value%' could not be detected",
-        self::NOT_READABLE     => "File '%value%' can not be read",
+        self::NOT_READABLE     => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 2 - 2
library/Zend/Validate/File/IsCompressed.php

@@ -46,8 +46,8 @@ class Zend_Validate_File_IsCompressed extends Zend_Validate_File_MimeType
      */
     protected $_messageTemplates = array(
         self::FALSE_TYPE   => "File '%value%' is not compressed, '%type%' detected",
-        self::NOT_DETECTED => "The mimetype of file '%value%' could not been detected",
-        self::NOT_READABLE => "File '%value%' can not be read",
+        self::NOT_DETECTED => "The mimetype of file '%value%' could not be detected",
+        self::NOT_READABLE => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/IsImage.php

@@ -47,7 +47,7 @@ class Zend_Validate_File_IsImage extends Zend_Validate_File_MimeType
     protected $_messageTemplates = array(
         self::FALSE_TYPE   => "File '%value%' is no image, '%type%' detected",
         self::NOT_DETECTED => "The mimetype of file '%value%' could not be detected",
-        self::NOT_READABLE => "File '%value%' can not be read",
+        self::NOT_READABLE => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/Md5.php

@@ -47,7 +47,7 @@ class Zend_Validate_File_Md5 extends Zend_Validate_File_Hash
     protected $_messageTemplates = array(
         self::DOES_NOT_MATCH => "File '%value%' does not match the given md5 hashes",
         self::NOT_DETECTED   => "A md5 hash could not be evaluated for the given file",
-        self::NOT_FOUND      => "File '%value%' could not be found",
+        self::NOT_FOUND      => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/MimeType.php

@@ -48,7 +48,7 @@ class Zend_Validate_File_MimeType extends Zend_Validate_Abstract
     protected $_messageTemplates = array(
         self::FALSE_TYPE   => "File '%value%' has a false mimetype of '%type%'",
         self::NOT_DETECTED => "The mimetype of file '%value%' could not be detected",
-        self::NOT_READABLE => "File '%value%' can not be read",
+        self::NOT_READABLE => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/Sha1.php

@@ -47,7 +47,7 @@ class Zend_Validate_File_Sha1 extends Zend_Validate_File_Hash
     protected $_messageTemplates = array(
         self::DOES_NOT_MATCH => "File '%value%' does not match the given sha1 hashes",
         self::NOT_DETECTED   => "A sha1 hash could not be evaluated for the given file",
-        self::NOT_FOUND      => "File '%value%' could not be found",
+        self::NOT_FOUND      => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/Size.php

@@ -48,7 +48,7 @@ class Zend_Validate_File_Size extends Zend_Validate_Abstract
     protected $_messageTemplates = array(
         self::TOO_BIG   => "Maximum allowed size for file '%value%' is '%max%' but '%size%' detected",
         self::TOO_SMALL => "Minimum expected size for file '%value%' is '%min%' but '%size%' detected",
-        self::NOT_FOUND => "File '%value%' could not be found",
+        self::NOT_FOUND => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/File/WordCount.php

@@ -48,7 +48,7 @@ class Zend_Validate_File_WordCount extends Zend_Validate_File_Count
     protected $_messageTemplates = array(
         self::TOO_MUCH => "Too much words, maximum '%max%' are allowed but '%count%' were counted",
         self::TOO_LESS => "Too less words, minimum '%min%' are expected but '%count%' were counted",
-        self::NOT_FOUND => "File '%value%' could not be found",
+        self::NOT_FOUND => "File '%value%' is not readable or does not exist",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/Float.php

@@ -44,7 +44,7 @@ class Zend_Validate_Float extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID   => "Invalid type given, value should be float, string, or integer",
+        self::INVALID   => "Invalid type given. String, integer or float expected",
         self::NOT_FLOAT => "'%value%' does not appear to be a float",
     );
 

+ 1 - 1
library/Zend/Validate/Hex.php

@@ -41,7 +41,7 @@ class Zend_Validate_Hex extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID => "Invalid type given, value should be a string",
+        self::INVALID => "Invalid type given. String expected",
         self::NOT_HEX => "'%value%' has not only hexadecimal digit characters",
     );
 

+ 1 - 1
library/Zend/Validate/Hostname.php

@@ -61,7 +61,7 @@ class Zend_Validate_Hostname extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID                 => "Invalid type given, value should be a string",
+        self::INVALID                 => "Invalid type given. String expected",
         self::IP_ADDRESS_NOT_ALLOWED  => "'%value%' appears to be an IP address, but IP addresses are not allowed",
         self::UNKNOWN_TLD             => "'%value%' appears to be a DNS hostname but cannot match TLD against known list",
         self::INVALID_DASH            => "'%value%' appears to be a DNS hostname but contains a dash in an invalid position",

+ 1 - 1
library/Zend/Validate/Int.php

@@ -44,7 +44,7 @@ class Zend_Validate_Int extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID => "Invalid type given, value should be string or integer",
+        self::INVALID => "Invalid type given. String or integer expected",
         self::NOT_INT => "'%value%' does not appear to be an integer",
     );
 

+ 1 - 1
library/Zend/Validate/Ip.php

@@ -39,7 +39,7 @@ class Zend_Validate_Ip extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID        => "Invalid type given, value should be a string",
+        self::INVALID        => "Invalid type given. String expected",
         self::NOT_IP_ADDRESS => "'%value%' does not appear to be a valid IP address",
     );
 

+ 1 - 1
library/Zend/Validate/Isbn.php

@@ -44,7 +44,7 @@ class Zend_Validate_Isbn extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID => "Invalid type given, value should be string or integer",
+        self::INVALID => "Invalid type given. String or integer expected",
         self::NO_ISBN => "'%value%' is no valid ISBN number",
     );
 

+ 1 - 1
library/Zend/Validate/NotEmpty.php

@@ -70,7 +70,7 @@ class Zend_Validate_NotEmpty extends Zend_Validate_Abstract
      */
     protected $_messageTemplates = array(
         self::IS_EMPTY => "Value is required and can't be empty",
-        self::INVALID  => "Invalid type given, value should be float, string, array, boolean or integer",
+        self::INVALID  => "Invalid type given. String, integer, float, boolean or array expected",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/PostCode.php

@@ -44,7 +44,7 @@ class Zend_Validate_PostCode extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID  => "Invalid type given. The value should be a string or a integer",
+        self::INVALID  => "Invalid type given. String or integer expected",
         self::NO_MATCH => "'%value%' does not appear to be a postal code",
     );
 

+ 1 - 1
library/Zend/Validate/Regex.php

@@ -40,7 +40,7 @@ class Zend_Validate_Regex extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID   => "Invalid type given, value should be string, integer or float",
+        self::INVALID   => "Invalid type given. String, integer or float expected",
         self::NOT_MATCH => "'%value%' does not match against pattern '%pattern%'",
         self::ERROROUS  => "There was an internal error while using the pattern '%pattern%'",
     );

+ 1 - 1
library/Zend/Validate/Sitemap/Changefreq.php

@@ -52,7 +52,7 @@ class Zend_Validate_Sitemap_Changefreq extends Zend_Validate_Abstract
      */
     protected $_messageTemplates = array(
         self::NOT_VALID => "'%value%' is no valid sitemap changefreq",
-        self::INVALID   => "Invalid type given, the value should be a string",
+        self::INVALID   => "Invalid type given. String expected",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/Sitemap/Lastmod.php

@@ -58,7 +58,7 @@ class Zend_Validate_Sitemap_Lastmod extends Zend_Validate_Abstract
      */
     protected $_messageTemplates = array(
         self::NOT_VALID => "'%value%' is no valid sitemap lastmod",
-        self::INVALID   => "Invalid type given, the value should be a string",
+        self::INVALID   => "Invalid type given. String expected",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/Sitemap/Loc.php

@@ -57,7 +57,7 @@ class Zend_Validate_Sitemap_Loc extends Zend_Validate_Abstract
      */
     protected $_messageTemplates = array(
         self::NOT_VALID => "'%value%' is no valid sitemap location",
-        self::INVALID   => "Invalid type given, the value should be a string",
+        self::INVALID   => "Invalid type given. String expected",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/Sitemap/Priority.php

@@ -52,7 +52,7 @@ class Zend_Validate_Sitemap_Priority extends Zend_Validate_Abstract
      */
     protected $_messageTemplates = array(
         self::NOT_VALID => "'%value%' is no valid sitemap priority",
-        self::INVALID   => "Invalid type given, the value should be a integer, a float or a numeric string",
+        self::INVALID   => "Invalid type given. Numeric string, integer or float expected",
     );
 
     /**

+ 1 - 1
library/Zend/Validate/StringLength.php

@@ -40,7 +40,7 @@ class Zend_Validate_StringLength extends Zend_Validate_Abstract
      * @var array
      */
     protected $_messageTemplates = array(
-        self::INVALID   => "Invalid type given, value should be a string",
+        self::INVALID   => "Invalid type given. String expected",
         self::TOO_SHORT => "'%value%' is less than %min% characters long",
         self::TOO_LONG  => "'%value%' is more than %max% characters long",
     );

+ 42 - 42
resources/languages/en/Zend_Validate.php

@@ -25,12 +25,12 @@
  */
 return array(
     // Zend_Validate_Alnum
-    "Invalid type given, value should be float, string, or integer" => "Invalid type given, value should be float, string, or integer",
+    "Invalid type given. String, integer or float expected" => "Invalid type given. String, integer or float expected",
     "'%value%' contains characters which are non alphabetic and no digits" => "'%value%' contains characters which are non alphabetic and no digits",
     "'%value%' is an empty string" => "'%value%' is an empty string",
 
     // Zend_Validate_Alpha
-    "Invalid type given, value should be a string" => "Invalid type given, value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
     "'%value%' contains non alphabetic characters" => "'%value%' contains non alphabetic characters",
     "'%value%' is an empty string" => "'%value%' is an empty string",
 
@@ -38,7 +38,7 @@ return array(
     "'%value%' failed checksum validation" => "'%value%' failed checksum validation",
     "'%value%' contains invalid characters" => "'%value%' contains invalid characters",
     "'%value%' should have a length of %length% characters" => "'%value%' should have a length of %length% characters",
-    "Invalid type given, value should be string" => "Invalid type given, value should be string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
 
     // Zend_Validate_Between
     "'%value%' is not between '%min%' and '%max%', inclusively" => "'%value%' is not between '%min%' and '%max%', inclusively",
@@ -46,41 +46,41 @@ return array(
 
     // Zend_Validate_Callback
     "'%value%' is not valid" => "'%value%' is not valid",
-    "Failure within the callback, exception returned" => "Failure within the callback, exception returned",
+    "An exception has been raised within the callback" => "An exception has been raised within the callback",
 
     // Zend_Validate_Ccnum
     "'%value%' must contain between 13 and 19 digits" => "'%value%' must contain between 13 and 19 digits",
     "Luhn algorithm (mod-10 checksum) failed on '%value%'" => "Luhn algorithm (mod-10 checksum) failed on '%value%'",
 
     // Zend_Validate_CreditCard
-    "Luhn algorithm (mod-10 checksum) failed on '%value%'" => "Luhn algorithm (mod-10 checksum) failed on '%value%'",
+    "'%value%' seems to contain an invalid checksum" => "'%value%' seems to contain an invalid checksum",
     "'%value%' must contain only digits" => "'%value%' must contain only digits",
-    "Invalid type given, value should be a string" => "Invalid type given, value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
     "'%value%' contains an invalid amount of digits" => "'%value%' contains an invalid amount of digits",
     "'%value%' is not from an allowed institute" => "'%value%' is not from an allowed institute",
-    "Validation of '%value%' has been failed by the service" => "Validation of '%value%' has been failed by the service",
-    "The service returned a failure while validating '%value%'" => "The service returned a failure while validating '%value%'",
+    "'%value%' seems to be an invalid creditcard number" => "'%value%' seems to be an invalid creditcard number",
+    "An exception has been raised while validating '%value%'" => "An exception has been raised while validating '%value%'",
 
     // Zend_Validate_Date
-    "Invalid type given, value should be string, integer, array or Zend_Date" => "Invalid type given, value should be string, integer, array or Zend_Date",
+    "Invalid type given. String, integer, array or Zend_Date expected" => "Invalid type given. String, integer, array or Zend_Date expected",
     "'%value%' does not appear to be a valid date" => "'%value%' does not appear to be a valid date",
     "'%value%' does not fit the date format '%format%'" => "'%value%' does not fit the date format '%format%'",
 
     // Zend_Validate_Db_Abstract
-    "No record matching %value% was found" => "No record matching %value% was found",
-    "A record matching %value% was found" => "A record matching %value% was found",
+    "No record matching '%value%' was found" => "No record matching '%value%' was found",
+    "A record matching '%value%' was found" => "A record matching '%value%' was found",
 
     // Zend_Validate_Digits
-    "Invalid type given, value should be string, integer or float" => "Invalid type given, value should be string, integer or float",
-    "'%value%' contains characters which are not digits; but only digits are allowed" => "'%value%' contains characters which are not digits; but only digits are allowed",
+    "Invalid type given. String, integer or float expected" => "Invalid type given. String, integer or float expected",
+    "'%value%' must contain only digits" => "'%value%' must contain only digits",
     "'%value%' is an empty string" => "'%value%' is an empty string",
 
     // Zend_Validate_EmailAddress
-    "Invalid type given, value should be a string" => "Invalid type given, value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
     "'%value%' is no valid email address in the basic format local-part@hostname" => "'%value%' is no valid email address in the basic format local-part@hostname",
     "'%hostname%' is no valid hostname for email address '%value%'" => "'%hostname%' is no valid hostname for email address '%value%'",
     "'%hostname%' does not appear to have a valid MX record for the email address '%value%'" => "'%hostname%' does not appear to have a valid MX record for the email address '%value%'",
-    "'%hostname%' is not in a routable network segment. The email address '%value%' should not be resolved from public network." => "'%hostname%' is not in a routable network segment. The email address '%value%' should not be resolved from public network.",
+    "'%hostname%' is not in a routable network segment. The email address '%value%' should not be resolved from public network" => "'%hostname%' is not in a routable network segment. The email address '%value%' should not be resolved from public network",
     "'%localPart%' can not be matched against dot-atom format" => "'%localPart%' can not be matched against dot-atom format",
     "'%localPart%' can not be matched against quoted-string format" => "'%localPart%' can not be matched against quoted-string format",
     "'%localPart%' is no valid local part for email address '%value%'" => "'%localPart%' is no valid local part for email address '%value%'",
@@ -93,23 +93,23 @@ return array(
     // Zend_Validate_File_Crc32
     "File '%value%' does not match the given crc32 hashes" => "File '%value%' does not match the given crc32 hashes",
     "A crc32 hash could not be evaluated for the given file" => "A crc32 hash could not be evaluated for the given file",
-    "File '%value%' could not be found" => "File '%value%' could not be found",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_ExcludeExtension
     "File '%value%' has a false extension" => "File '%value%' has a false extension",
-    "File '%value%' could not be found" => "File '%value%' could not be found",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_ExcludeMimeType
     "File '%value%' has a false mimetype of '%type%'" => "File '%value%' has a false mimetype of '%type%'",
     "The mimetype of file '%value%' could not be detected" => "The mimetype of file '%value%' could not be detected",
-    "File '%value%' can not be read" => "File '%value%' can not be read",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_Exists
     "File '%value%' does not exist" => "File '%value%' does not exist",
 
     // Zend_Validate_File_Extension
     "File '%value%' has a false extension" => "File '%value%' has a false extension",
-    "File '%value%' could not be found" => "File '%value%' could not be found",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_FilesSize
     "All files in sum should have a maximum size of '%max%' but '%size%' were detected" => "All files in sum should have a maximum size of '%max%' but '%size%' were detected",
@@ -119,7 +119,7 @@ return array(
     // Zend_Validate_File_Hash
     "File '%value%' does not match the given hashes" => "File '%value%' does not match the given hashes",
     "A hash could not be evaluated for the given file" => "A hash could not be evaluated for the given file",
-    "File '%value%' could not be found" => "File '%value%' could not be found",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_ImageSize
     "Maximum allowed width for image '%value%' should be '%maxwidth%' but '%width%' detected" => "Maximum allowed width for image '%value%' should be '%maxwidth%' but '%width%' detected",
@@ -127,27 +127,27 @@ return array(
     "Maximum allowed height for image '%value%' should be '%maxheight%' but '%height%' detected" => "Maximum allowed height for image '%value%' should be '%maxheight%' but '%height%' detected",
     "Minimum expected height for image '%value%' should be '%minheight%' but '%height%' detected" => "Minimum expected height for image '%value%' should be '%minheight%' but '%height%' detected",
     "The size of image '%value%' could not be detected" => "The size of image '%value%' could not be detected",
-    "File '%value%' can not be read" => "File '%value%' can not be read",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_IsCompressed
     "File '%value%' is not compressed, '%type%' detected" => "File '%value%' is not compressed, '%type%' detected",
     "The mimetype of file '%value%' could not be detected" => "The mimetype of file '%value%' could not be detected",
-    "File '%value%' can not be read" => "File '%value%' can not be read",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_IsImage
     "File '%value%' is no image, '%type%' detected" => "File '%value%' is no image, '%type%' detected",
     "The mimetype of file '%value%' could not be detected" => "The mimetype of file '%value%' could not be detected",
-    "File '%value%' can not be read" => "File '%value%' can not be read",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_Md5
     "File '%value%' does not match the given md5 hashes" => "File '%value%' does not match the given md5 hashes",
     "A md5 hash could not be evaluated for the given file" => "A md5 hash could not be evaluated for the given file",
-    "File '%value%' could not be found" => "File '%value%' could not be found",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_MimeType
     "File '%value%' has a false mimetype of '%type%'" => "File '%value%' has a false mimetype of '%type%'",
     "The mimetype of file '%value%' could not be detected" => "The mimetype of file '%value%' could not be detected",
-    "File '%value%' can not be read" => "File '%value%' can not be read",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_NotExists
     "File '%value%' exists" => "File '%value%' exists",
@@ -155,12 +155,12 @@ return array(
     // Zend_Validate_File_Sha1
     "File '%value%' does not match the given sha1 hashes" => "File '%value%' does not match the given sha1 hashes",
     "A sha1 hash could not be evaluated for the given file" => "A sha1 hash could not be evaluated for the given file",
-    "File '%value%' could not be found" => "File '%value%' could not be found",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_Size
     "Maximum allowed size for file '%value%' is '%max%' but '%size%' detected" => "Maximum allowed size for file '%value%' is '%max%' but '%size%' detected",
     "Minimum expected size for file '%value%' is '%min%' but '%size%' detected" => "Minimum expected size for file '%value%' is '%min%' but '%size%' detected",
-    "File '%value%' could not be found" => "File '%value%' could not be found",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_File_Upload
     "File '%value%' exceeds the defined ini size" => "File '%value%' exceeds the defined ini size",
@@ -177,21 +177,21 @@ return array(
     // Zend_Validate_File_WordCount
     "Too much words, maximum '%max%' are allowed but '%count%' were counted" => "Too much words, maximum '%max%' are allowed but '%count%' were counted",
     "Too less words, minimum '%min%' are expected but '%count%' were counted" => "Too less words, minimum '%min%' are expected but '%count%' were counted",
-    "File '%value%' could not be found" => "File '%value%' could not be found",
+    "File '%value%' is not readable or does not exist" => "File '%value%' is not readable or does not exist",
 
     // Zend_Validate_Float
-    "Invalid type given, value should be float, string, or integer" => "Invalid type given, value should be float, string, or integer",
+    "Invalid type given. String, integer or float expected" => "Invalid type given. String, integer or float expected",
     "'%value%' does not appear to be a float" => "'%value%' does not appear to be a float",
 
     // Zend_Validate_GreaterThan
     "'%value%' is not greater than '%min%'" => "'%value%' is not greater than '%min%'",
 
     // Zend_Validate_Hex
-    "Invalid type given, value should be a string" => "Invalid type given, value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
     "'%value%' has not only hexadecimal digit characters" => "'%value%' has not only hexadecimal digit characters",
 
     // Zend_Validate_Hostname
-    "Invalid type given, value should be a string" => "Invalid type given, value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
     "'%value%' appears to be an IP address, but IP addresses are not allowed" => "'%value%' appears to be an IP address, but IP addresses are not allowed",
     "'%value%' appears to be a DNS hostname but cannot match TLD against known list" => "'%value%' appears to be a DNS hostname but cannot match TLD against known list",
     "'%value%' appears to be a DNS hostname but contains a dash in an invalid position" => "'%value%' appears to be a DNS hostname but contains a dash in an invalid position",
@@ -215,51 +215,51 @@ return array(
     "'%value%' was not found in the haystack" => "'%value%' was not found in the haystack",
 
     // Zend_Validate_Int
-    "Invalid type given, value should be string or integer" => "Invalid type given, value should be string or integer",
+    "Invalid type given. String or integer expected" => "Invalid type given. String or integer expected",
     "'%value%' does not appear to be an integer" => "'%value%' does not appear to be an integer",
 
     // Zend_Validate_Ip
-    "Invalid type given, value should be a string" => "Invalid type given, value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
     "'%value%' does not appear to be a valid IP address" => "'%value%' does not appear to be a valid IP address",
 
     // Zend_Validate_Isbn
-    "Invalid type given, value should be string or integer" => "Invalid type given, value should be string or integer",
+    "Invalid type given. String or integer expected" => "Invalid type given. String or integer expected",
     "'%value%' is no valid ISBN number" => "'%value%' is no valid ISBN number",
 
     // Zend_Validate_LessThan
     "'%value%' is not less than '%max%'" => "'%value%' is not less than '%max%'",
 
     // Zend_Validate_NotEmpty
-    "Invalid type given, value should be float, string, array, boolean or integer" => "Invalid type given, value should be float, string, array, boolean or integer",
+    "Invalid type given. String, integer, float, boolean or array expected" => "Invalid type given. String, integer, float, boolean or array expected",
     "Value is required and can't be empty" => "Value is required and can't be empty",
 
     // Zend_Validate_PostCode
-    "Invalid type given. The value should be a string or a integer" => "Invalid type given. The value should be a string or a integer",
+    "Invalid type given. String or integer expected" => "Invalid type given. String or integer expected",
     "'%value%' does not appear to be a postal code" => "'%value%' does not appear to be a postal code",
 
     // Zend_Validate_Regex
-    "Invalid type given, value should be string, integer or float" => "Invalid type given, value should be string, integer or float",
+    "Invalid type given. String, integer or float expected" => "Invalid type given. String, integer or float expected",
     "'%value%' does not match against pattern '%pattern%'" => "'%value%' does not match against pattern '%pattern%'",
     "There was an internal error while using the pattern '%pattern%'" => "There was an internal error while using the pattern '%pattern%'",
 
     // Zend_Validate_Sitemap_Changefreq
     "'%value%' is no valid sitemap changefreq" => "'%value%' is no valid sitemap changefreq",
-    "Invalid type given, the value should be a string" => "Invalid type given, the value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
 
     // Zend_Validate_Sitemap_Lastmod
     "'%value%' is no valid sitemap lastmod" => "'%value%' is no valid sitemap lastmod",
-    "Invalid type given, the value should be a string" => "Invalid type given, the value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
 
     // Zend_Validate_Sitemap_Loc
     "'%value%' is no valid sitemap location" => "'%value%' is no valid sitemap location",
-    "Invalid type given, the value should be a string" => "Invalid type given, the value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
 
     // Zend_Validate_Sitemap_Priority
     "'%value%' is no valid sitemap priority" => "'%value%' is no valid sitemap priority",
-    "Invalid type given, the value should be a integer, a float or a numeric string" => "Invalid type given, the value should be a integer, a float or a numeric string",
+    "Invalid type given. Numeric string, integer or float expected" => "Invalid type given. Numeric string, integer or float expected",
 
     // Zend_Validate_StringLength
-    "Invalid type given, value should be a string" => "Invalid type given, value should be a string",
+    "Invalid type given. String expected" => "Invalid type given. String expected",
     "'%value%' is less than %min% characters long" => "'%value%' is less than %min% characters long",
     "'%value%' is more than %max% characters long" => "'%value%' is more than %max% characters long",
 );

+ 1 - 1
tests/Zend/Validate/DigitsTest.php

@@ -127,7 +127,7 @@ class Zend_Validate_DigitsTest extends PHPUnit_Framework_TestCase
         $this->assertFalse($this->_validator->isValid('#'));
         $messages = $this->_validator->getMessages();
         $arrayExpected = array(
-            Zend_Validate_Digits::NOT_DIGITS => '\'#\' contains characters which are not digits; but only digits are allowed'
+            Zend_Validate_Digits::NOT_DIGITS => '\'#\' must contain only digits'
             );
         $this->assertThat($messages, $this->identicalTo($arrayExpected));
     }

+ 1 - 1
tests/Zend/Validate/File/ImageSizeTest.php

@@ -86,7 +86,7 @@ class Zend_Validate_File_ImageSizeTest extends PHPUnit_Framework_TestCase
         $validator = new Zend_Validate_File_ImageSize(array('minwidth' => 0, 'minheight' => 10, 'maxwidth' => 1000, 'maxheight' => 2000));
         $this->assertEquals(false, $validator->isValid(dirname(__FILE__) . '/_files/nofile.jpg'));
         $failures = $validator->getMessages();
-        $this->assertContains('can not be read', $failures['fileImageSizeNotReadable']);
+        $this->assertContains('is not readable', $failures['fileImageSizeNotReadable']);
 
         $file['name'] = 'TestName';
         $validator = new Zend_Validate_File_ImageSize(array('minwidth' => 0, 'minheight' => 10, 'maxwidth' => 1000, 'maxheight' => 2000));

+ 1 - 1
tests/Zend/Validate/Sitemap/ChangefreqTest.php

@@ -106,7 +106,7 @@ class Zend_Validate_Sitemap_ChangefreqTest extends PHPUnit_Framework_TestCase
         foreach ($values as $value) {
             $this->assertSame(false, $this->_validator->isValid($value));
             $messages = $this->_validator->getMessages();
-            $this->assertContains('should be a string', current($messages));
+            $this->assertContains('String expected', current($messages));
         }
     }
 }

+ 1 - 1
tests/Zend/Validate/Sitemap/LastmodTest.php

@@ -118,7 +118,7 @@ class Zend_Validate_Sitemap_LastmodTest extends PHPUnit_Framework_TestCase
         foreach ($values as $value) {
             $this->assertSame(false, $this->_validator->isValid($value));
             $messages = $this->_validator->getMessages();
-            $this->assertContains('should be a string', current($messages));
+            $this->assertContains('String expected', current($messages));
         }
     }
 }

+ 1 - 1
tests/Zend/Validate/Sitemap/LocTest.php

@@ -113,7 +113,7 @@ class Zend_Validate_Sitemap_LocTest extends PHPUnit_Framework_TestCase
         foreach ($values as $value) {
             $this->assertSame(false, $this->_validator->isValid($value));
             $messages = $this->_validator->getMessages();
-            $this->assertContains('should be a string', current($messages));
+            $this->assertContains('String expected', current($messages));
         }
     }
 

+ 1 - 1
tests/Zend/Validate/Sitemap/PriorityTest.php

@@ -105,7 +105,7 @@ class Zend_Validate_Sitemap_PriorityTest extends PHPUnit_Framework_TestCase
         foreach ($values as $value) {
             $this->assertSame(false, $this->_validator->isValid($value));
             $messages = $this->_validator->getMessages();
-            $this->assertContains('should be a integer', current($messages));
+            $this->assertContains('integer or float expected', current($messages));
         }
     }
 }