@Test
public void testExistingObjectTypeThrowsException(){

  when(objectManager.getObjectType("someObjectType")).thenReturn(new ObjectTypeEntity());
  InvalidArgumentException ex = assertThrows(InvalidArgumentException.class, () -> handler.assertObjectTypeNotExists("someObjectType"));
  assertEquals(set("object.type.exist"), set(ex.getValidationErrors(), InvalidArgumentException.ValidationError::getMessageTemplate));
}