Issue Type: Bug Created: 2011-12-05T10:17:21.000+0000 Last Updated: 2012-02-24T18:14:12.000+0000 Status: Open Fix version(s): Reporter: Antonio J García Lagar (ajgarlag) Assignee: Thomas Weidner (thomas) Tags: - Zend_Validate
Related issues: Attachments: - Zend_Validate_DateTest-group-annotations.diff
When validating an invalid date given as an array the validator the error message should Zend_Validate_Date::INVALID_DATE instead of Zend_Validate_Date::FALSEFORMAT
Posted by Antonio J García Lagar (ajgarlag) on 2011-12-06T15:20:57.000+0000
My first patch ;)
Posted by Adam Lundrigan (adamlundrigan) on 2011-12-07T02:05:53.000+0000
I've tested your patch...it applies cleanly and works as expected with no visible side-effects. I'm not intimately familiar with this class, and also can't comment on whether changing error message behavior like this is considered a BC break, so I'll have to defer to the component maintainer who can commit your patch if it passes his inspection.
One thing to note for future reference is that your test case should use the @group annotation to denote the issue the test is associated with, like so:
<pre class="highlight"> /** * @group ZF-11926 */ public function testArrayValidationErrorMessage() ...
I assume you modeled your test after the existing ones in that class, and many of those break this rule, so that omission is completely understandable. Using that docblock annotation format allows us to run tests in isolation (ie: to run just tests for this bug, run ./runtests.sh ZF-11926 from tests folder).
Thank you for your contribution!
Posted by Antonio J García Lagar (ajgarlag) on 2011-12-07T07:30:24.000+0000
Thanks for your comment.
I've edited the docblock to annotate the test group properly.
Posted by Antonio J García Lagar (ajgarlag) on 2011-12-07T07:35:27.000+0000
As a bonus for my previous fault I've added a patch to fix the group annotations for the other tests.
Have you found an issue?
See the Overview section for more details.