-
Notifications
You must be signed in to change notification settings - Fork 301
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
catch validation errors during patch serialization
- we want to force triggering of validation exceptions during serialiation - add unit test to verify that validation exception is raised on patch - a validation exception should be raised when a validation error occurs during serialization - create a serializer class that automatically throws the validation exception - uses marshmallow's ValidationError exception, but in theory any exception could be used to force the check in order to pass them through to the flask-restless validations exceptions handler and thus have it return meaningful errors to client
- Loading branch information
Kiptoo Magutt
committed
Feb 6, 2018
1 parent
8e32477
commit 287b085
Showing
4 changed files
with
56 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
-r install.txt | ||
unittest2 | ||
marshmallow |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters