Added tests for ValidationError handling