Fix issue with the error messages

Many of the errors where incorrectly showing "Required field is not
provided" when the field was provided but not valid.
This was raised by @ron on PR #3825
This commit is contained in:
HelderSepu
2017-10-28 16:21:40 -04:00
parent 4eae9b681b
commit ec2179f019
2 changed files with 13 additions and 13 deletions

View File

@@ -524,7 +524,7 @@ describe("utils", function() {
type: "boolean",
value: "test string"
}
assertValidateParam(param, ["Required field is not provided"])
assertValidateParam(param, ["Value must be a boolean"])
// valid boolean value
param = {
@@ -584,7 +584,7 @@ describe("utils", function() {
type: "number",
value: "test"
}
assertValidateParam(param, ["Required field is not provided"])
assertValidateParam(param, ["Value must be a number"])
// invalid number, undefined value
param = {
@@ -666,7 +666,7 @@ describe("utils", function() {
type: "integer",
value: "test"
}
assertValidateParam(param, ["Required field is not provided"])
assertValidateParam(param, ["Value must be an integer"])
// invalid integer, undefined value
param = {