Benjamin Dulau
a5a2dfaaa6
[ImageValidator] Added dedicated ImageValidator class with min width, max width, min height and max height validations
2011-09-04 17:28:46 +02:00
Fabien Potencier
e7b2d2d659
merged 2.0 branch
2011-09-04 09:28:37 +02:00
Evan Kaufman
639513a67a
Per the [documentation][1], the NotBlank
constraint should be using the empty
language construct, otherwise it will not trigger on, for example, a boolean false from an unchecked checkbox field.
...
[1]: http://symfony.com/doc/2.0/reference/constraints/NotBlank.html
2011-09-02 09:37:48 +02:00
stealth35
5a470103f0
[Validator] FileValidator allow MIME with wildcard
2011-09-01 16:10:16 +02:00
Fabien Potencier
e42a2dede1
[Validator] fixed unit tests when intl is not installed
2011-07-20 14:45:35 +02:00
Deni
0f328d228b
[Validator] Fixed using the strict option in the choice validator.
2011-07-16 21:16:21 +04:00
Fabien Potencier
c04512086e
[Validator] fixed error message property path when a collection error occurs
2011-07-16 00:29:54 +02:00
Fabien Potencier
88d915d175
[Validator] fixed Min and Max validator when the input value is not a number (now return an error message instead of an exception which does not make sense in this context)
2011-07-12 17:40:02 +02:00
marc.weistroff
df57e0fe9a
[Validator] Added strict option to ChoiceConstraint.
2011-07-07 15:11:36 +02:00
Victor Berchet
d58ba34246
[Validator] Consider the ini directive 'upload_max_filesize' while validating an uploaded file (fixes GH-1441)
2011-07-05 20:05:50 +02:00
Benjamin Eberlei
9069d06732
Fix tests to run with Doctrine Common AnnotationRegistry
2011-07-03 16:44:01 +02:00
Johannes Schmitt
efcb435268
updated to doctrine changes
2011-06-30 12:03:19 +02:00
Fabien Potencier
46680d4565
[FrameworkBundle] switched back to Doctrine Common 2.1
2011-06-24 14:11:31 +02:00
Fabien Potencier
f322a4a99d
fixed CS
2011-06-23 13:39:36 +02:00
Jordi Boggiano
159fc0edf0
[Validator] Added symbols to IDNs validation
2011-06-20 13:52:36 +02:00
Jordi Boggiano
c827faf694
[Validator] Add support for IDNs and custom TLDs
2011-06-20 12:57:46 +02:00
Fabien Potencier
0805c6f963
[Validator] removed MX test (tests should work with Internet down)
2011-06-16 15:22:16 +02:00
stloyd
edf4b87dcb
Add missing "tearDown" functions, and some missing variable declaration (this saves for me almost 20MB when run all tests)
...
Force AsseticBundle tests to use TestCase
Fix test for DoctrineBundle to use TestCase
2011-06-16 15:06:36 +02:00
stloyd
2b0c3526d8
Increase code coverage for: YamlParser, Validators, PhpEngine + Helpers, HttpFoundation
...
Revert failing asserts for UrlValidator
Mark as incomplete instead of commenting them out
2011-06-16 11:43:27 +02:00
stloyd
99f9337517
Additional tests for PhpEngine + Helpers
...
More tests for UrlValidator
2011-06-16 11:42:29 +02:00
stloyd
450ed85aa4
Additional tests for DateTimeValidator, EmailValidator and UrlValidator
2011-06-16 11:42:28 +02:00
Fabien Potencier
c7d5fd16e0
fixed CS
2011-06-15 13:46:46 +02:00
Fabien Potencier
c5223bbcd1
merged branch vicb/file (PR #1317 )
...
Commits
-------
9d6357c
[HttpFoundation] Document the changes to the File classes
136b80a
[HttFoundation] Add File::getExtension() as \SplFileInfo::getExtension() was introduced in PHP 5.3.6
38b3b74
[HttpKernel] Fix and test previous commit
ac0c00c
[HttpFoundation] Make File extends \SplFileInfo
Discussion
----------
[HttpFoundation] Make File extends \SplFileInfo
This is a rebased version of [PR 674](https://github.com/symfony/symfony/pull/674 ).
* File: The API has changed (now extends \SplFileInfo),
* File: move() creates the target directory when it does not exist
* UploadedFile: introduction of getClientXXX() methods (for Size, OriginalName, MimeType)
If this PR does not get merged UploadedFile should at least be fixed: [Client.php](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/Client.php#L124 ) relies on a last parameter which is no more defined and which is used to bypass [move_uploaded_file()](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpFoundation/File/UploadedFile.php#L155 ) in test mode.
If this could be merged, I'll detail the changes in UPDATE.md
---------------------------------------------------------------------------
by fabpot at 2011/06/14 08:20:59 -0700
I'll merge it. Can you update the UPDATE file?
---------------------------------------------------------------------------
by vicb at 2011/06/14 09:24:01 -0700
done
2011-06-15 08:57:16 +02:00
Victor Berchet
ac0c00c6e8
[HttpFoundation] Make File extends \SplFileInfo
2011-06-14 10:47:04 +02:00
Albert Jessurum
ca52a04f5e
[Validator] Allow DateTime objects as valid Times
2011-06-09 15:47:51 +02:00
Fabien Potencier
17cd08dc6c
fixed CS
2011-06-08 19:56:59 +02:00
stloyd
3ea2a32c53
Refactor validators constraints:
...
- remove need for defining "getTargets()" method as 95% of validators use same one
- replace abstract "Constraint::getTargets()" with one that use 95% of validators
- add additional tests for "Constraint::getTargets()" method
- remove unused "use" statement in Constraint\Valid
2011-05-25 10:51:35 +02:00
Johannes Schmitt
ddc00fa0f6
removed obsolete compiler pass
2011-05-20 06:59:30 +02:00
Johannes Schmitt
6c0b0449a6
Merge remote branch 'origin/master' into annotations
...
Conflicts:
UPDATE.md
src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Configuration.php
src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php
2011-05-19 22:49:59 +02:00
Johannes Schmitt
42fb34b647
fixed tests
2011-05-19 22:46:34 +02:00
Dirk Pahl
361c67f54f
[Form] Add test for the handling of array values in the constraint violation
2011-05-18 23:48:32 +02:00
Johannes Schmitt
796d9af0c4
some updates
2011-05-16 22:26:24 +02:00
Johannes Schmitt
2d8afd8dd6
Merge remote branch 'origin/master' into annotations
...
Conflicts:
src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php
src/Symfony/Bundle/FrameworkBundle/Resources/config/validator.xml
src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/FrameworkExtensionTest.php
2011-05-14 12:51:05 +02:00
Joseph Bielawski
bf87a35595
Better comment about no test IP6 addresses for "FILTER_FLAG_NO_RES_RANGE"
2011-05-11 14:18:45 -07:00
stloyd
5997b930a5
Refactoring of IpValidator to use native php filter extension, also adding additional flag support and test cover.
2011-05-11 13:19:03 +02:00
Pascal Borreli
b4e220dce9
[Validator] Added unit tests
2011-05-08 21:52:34 +00:00
Johannes Schmitt
f7e03f2d87
Merge remote branch 'origin/master' into annotations
...
Conflicts:
UPDATE.md
src/Symfony/Bundle/DoctrineBundle/Resources/config/orm.xml
src/Symfony/Bundle/DoctrineBundle/Tests/DependencyInjection/AbstractDoctrineExtensionTest.php
2011-05-08 07:28:23 +02:00
Daniel Holmes
8d96f6c009
[Validator] fixed namespaces for validator tests
2011-05-06 02:37:03 +10:00
Johannes Schmitt
f2160b2e79
[Validator] updated fixtures
2011-05-01 14:50:28 +02:00
Johannes Schmitt
7e26575bbd
[FrameworkBundle] added framework-wide annotation reader, updated validator tests
2011-04-29 15:54:44 +02:00
Igor Wiedler
afcdbf8b79
[Validator] add IPv6 support to UrlValidator
2011-04-22 17:07:44 +02:00
Fabien Potencier
1118fbdae7
[Validator] fixed unit test
2011-04-22 08:41:58 +02:00
Kris Wallsmith
9b3ce98432
[Validator] added test skip if APC is not enabled for the CLI
2011-04-06 04:16:16 -07:00
Kris Wallsmith
9ff2ca7f1d
[Validator] fixed apc cache
2011-04-06 04:07:37 -07:00
Fabien Potencier
a9160eee70
[Validator] made fields the default option for Collection constraint
2011-03-31 15:36:04 +02:00
Fabien Potencier
f92055ce42
[Validator] renamed methods that do not follow CS
...
requiredOptions -> getRequiredOptions
targets -> getTargets
defaultOption -> getDefaultOption
2011-03-30 23:18:20 +02:00
Fabien Potencier
525702b5c6
[Validator] renamed method to follow CS
2011-03-30 23:10:30 +02:00
Johannes M. Schmitt
7887f04dc2
removed Assert prefix from all constraints, renamed annotation namespace to assert
2011-03-26 15:26:05 +01:00
Bernhard Schussek
3e29348d21
[Validator] Added support for static callbacks to Callback constraint
2011-03-25 01:36:58 +01:00
Bernhard Schussek
9c6a6e13bf
[Validator] Renamed Execute constraint to Callback
2011-03-25 01:34:35 +01:00
Fabien Potencier
8c423edfef
replaced symfony-project.org by symfony.com
2011-03-06 12:40:06 +01:00
Pascal Borreli
3a47fa6eed
[Tests] Fixed Typo
2011-03-01 18:58:08 +01:00
Bernhard Schussek
1a34743990
[Validator] Fixed: Collections annotated with @Valid may contain scalar values. These values are ignored by the GraphWalker
2011-02-03 13:21:37 +01:00
Bernhard Schussek
5ed4d91bb8
[Validator] Implemented Execute constraint
2011-02-03 11:00:03 +01:00
Thomas
e6dc155e89
fix validator class metadata warning
2011-02-02 11:37:41 +01:00
Jordi Boggiano
571c984625
[Validator] Skip tests that rely on Doctrine being present if its not
2011-01-30 09:18:18 +01:00
Bernhard Schussek
0c3ca26e6e
[Validator] Implemented traversing of \Traversable objects using the @Valid constraint. Can be disabled by setting the @Valid option 'traverse' to false
2011-01-28 09:19:32 +01:00
Bernhard Schussek
d327a90ff2
[Validator] Added namespace prefix support for XML and YAML loaders
2011-01-19 16:25:50 +01:00
Bernhard Schussek
2d7c47e488
[Validator] Each object is now only validated once for a given group
2011-01-19 16:25:50 +01:00
Bernhard Schussek
eed3c9a48c
[Validator] Added abstract method Constraint::targets() to define whether constraints can be put onto properties, classes or both
2011-01-19 16:25:50 +01:00
Bernhard Schussek
6ad22fd702
[Validator] Added ValidatorFactory for programmatically creating validators
2011-01-19 16:25:50 +01:00
Bernhard Schussek
fea37a3e95
[Validator] Added tests for AssertTypeValidator
2011-01-19 16:25:50 +01:00
Dominique Bongiraud
64fb94c725
normalized license messages in PHP files
2011-01-18 08:07:46 +01:00
Bernhard Schussek
39c9bf160e
[Validator] Implemented @Ip constraint
2011-01-03 22:07:15 +01:00
Bernhard Schussek
708c780213
[Validator] Renamed @Validation constraint to @Set
2011-01-03 22:06:52 +01:00
Bernhard Schussek
52ecffe51b
[Validator] Implemented Locale constraint
2011-01-02 10:41:09 +01:00
Jordi Boggiano
3d9b13f240
CS: Unified non-strict equality comparisons, put var on the right side
2010-12-21 08:51:27 +01:00
Bernhard Schussek
993257a83e
[Validator] Implemented Language constraint
2010-12-16 10:18:33 +01:00
Bernhard Schussek
fdb7f84c7d
[Locale][Form][Validator] Refactored code to new Locale component, implemented Country constraint
2010-12-16 10:18:33 +01:00
Johannes M. Schmitt
b3081c79e9
CS fixes
2010-12-13 11:10:55 +01:00
Fabien Potencier
48e30537c4
added exception when a loaded YAML resource is not an array
2010-12-12 08:39:37 +01:00
Bernhard Schussek
1b2ca259f1
[Validator] Fixed string-based constraint validators to accept empty values
2010-12-10 14:28:11 +01:00
Gustavo Falco
af291bb0f1
[Validator] Fixed UrlValidator to accept empty strings ( closes #9297 )
2010-12-10 14:28:07 +01:00
pablodip
984a857a96
[Validator] fixed the static method loader to not repeat the loading when the static method is in the parent classes
2010-12-10 14:27:49 +01:00
Kris Wallsmith
3e02eafc70
Fixed visibility of PHPUnit setUp and tearDown methods.
2010-12-06 15:52:23 +01:00
Bernhard Schussek
68cebd667a
[Validator] Group sequences must now always contain the group "<ClassName>" and never the group "Default" since that group is redefined by the group sequence
2010-11-19 07:11:26 +01:00
Bernhard Schussek
a71cad480a
[Validator] Added @validation:GroupSequence to annotation driver
2010-11-19 07:11:23 +01:00
Jordi Boggiano
b2bd7ce57d
[Validator] Skipping AnnotationLoader tests if doctrine-common is not present
2010-11-18 06:59:09 +01:00
Bernhard Schussek
940ce9aedf
[Validator] Group "Default" is now propagated to validated references when group sequences are validated
...
This conforms to JSR303 (see version 1.0 final, page 39).
2010-11-17 08:02:10 +01:00
Bernhard Schussek
6a148465da
[Validator][Form] Removed support for match-all group "*"
...
The constraint "Valid" does not accept any options or groups anymore. As per
JSR303 1.0 final, section 3.5.1 "Object graph validation" (page 39),
properties annotated with valid should be cascaded independent of the current
group (i.e. always). Thus the group "*" is not necessary anymore and was
removed from the "Valid" constraint in the Form validation.xml.
2010-11-17 08:02:06 +01:00
jeff
69cd21d8be
[Validator] Fixed annotation loader to not add parent constraints twice
2010-11-12 17:56:09 +01:00
Fabien Potencier
5b6d92df3c
fixed unit tests
2010-10-18 17:01:57 +02:00
Kris Wallsmith
5d4c80f27b
[Validator] removed DependencyInjection integration
2010-10-16 08:34:36 +02:00
Fabien Potencier
0fc8906feb
[Validator] forced all validation annotations to be in the validation namespace to avoid collisions, removed the need for the wrapping @Validation annotation
...
Before:
/**
* @Validation({@DateTime()})
*/
After:
/**
* @validation:DateTime()
*/
The @validation:Validation() construct is not needed anymore (it is still supported
as this is useful when you have several annotations with the same class).
So, the above is equivalent to:
/**
* @validation:Validation({@validation:DateTime()})
*/
2010-10-02 15:07:00 +02:00
Fabien Potencier
3b1e83380b
[Validator] removed the convention that error parameters are delimited with %%
2010-09-29 07:59:45 +02:00
Fabien Potencier
866c306dc8
removed the message interpolator system in the Validator component (i18n management should be done globally, not in a specific component)
2010-09-24 16:41:28 +02:00
Fabien Potencier
a141c98917
[HttpFoundation] moved File Component into the HttpFoundation one
2010-09-09 17:01:48 +02:00
Fabien Potencier
bf82cf42dd
renamed Symfony\Components to Symfony\Component
2010-08-20 23:09:55 +02:00