forked from mirror/Part-DB.Part-DB-server
Added some tests to constraint validators
This commit is contained in:
parent
e72b120c12
commit
2ebb4fef4c
12 changed files with 719 additions and 14 deletions
|
@ -53,7 +53,7 @@ class SelectableValidator extends ConstraintValidator
|
|||
|
||||
//Check type of value. Validating only works for StructuralDBElements
|
||||
if (!$value instanceof AbstractStructuralDBElement) {
|
||||
throw new UnexpectedValueException($value, 'StructuralDBElement');
|
||||
throw new UnexpectedValueException($value, AbstractStructuralDBElement::class);
|
||||
}
|
||||
|
||||
//Check if the value is not selectable -> show error message then.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue