mothership-ec / cog

Cog
Other
2 stars 3 forks source link

Form constraints for Vimeo and YouTube #485

Closed thomasjthomasj closed 8 years ago

thomasjthomasj commented 8 years ago

This PR adds a new namespace for custom Symfony constraints. They are directly in the form component to avoid confusion with the deprecated Validation component, since they are realistically only used on forms anyway.

Annoyingly, they can't really be unit tested because they are extensions of Symfony's own classes, so it might be an idea to abstract the actual validation to something else, but I'm not sure where a good place for that would be.