fix type conversion of const bool
`prop: {const: True}` should be converted to bool and not to integer. Change-Id: Ic3775a36c138d451dbad7615bc0e446528d8b0be Signed-off-by: Artem Goncharov <artem.goncharov@gmail.com>
This commit is contained in:
@@ -301,6 +301,9 @@ class JsonSchemaParser:
|
|||||||
if isinstance(const, str):
|
if isinstance(const, str):
|
||||||
obj = ConstraintString(**schema)
|
obj = ConstraintString(**schema)
|
||||||
return obj
|
return obj
|
||||||
|
if isinstance(const, bool):
|
||||||
|
obj = PrimitiveBoolean(**schema)
|
||||||
|
return obj
|
||||||
if isinstance(const, int):
|
if isinstance(const, int):
|
||||||
obj = ConstraintInteger(**schema)
|
obj = ConstraintInteger(**schema)
|
||||||
return obj
|
return obj
|
||||||
|
Reference in New Issue
Block a user