UpdateManager implements IUpdateManager { @Override public void setMultiHop(final IMessageUnitEntity msgUnit, final boolean isMultihop) throws PersistenceException { performUpdate((MessageUnitEntity) msgUnit, (MessageUnit jpaObject) -> { jpaObject.setMultiHop(isMultihop); }); }  @Override V storeMessageUnit(final T messageUnit); @Override boolean setProcessingState(final IMessageUnitEntity msgUnit, final ProcessingState currentProcState,
                                      final ProcessingState newProcState); @Override boolean setProcessingState(final IMessageUnitEntity msgUnit, final ProcessingState currentProcState,
                                      final ProcessingState newProcState, final String description); @Override void deleteMessageUnit(final IMessageUnitEntity messageUnit); @Override void setPModeId(final IMessageUnitEntity msgUnit, final String pmodeId); @Override void setMultiHop(final IMessageUnitEntity msgUnit, final boolean isMultihop); @Override void setPayloadInformation(final IUserMessageEntity userMessage, final Collection<IPayload> payloadInfo); @Override void setAddSOAPFault(final IErrorMessageEntity errorMessage, final boolean addSOAPFault);  }
@Test public void setMultiHop() throws PersistenceException { em.getTransaction().begin(); ErrorMessage errorMsgJPA = new ErrorMessage(TestData.error3); em.persist(errorMsgJPA); ErrorMessageEntity errorMsg = new ErrorMessageEntity(errorMsgJPA); em.getTransaction().commit(); assertNotEquals(T_NEW_MULTI_HOP, errorMsg.usesMultiHop()); updManager.setMultiHop(errorMsg, T_NEW_MULTI_HOP); assertEquals(T_NEW_MULTI_HOP, errorMsg.usesMultiHop()); em.refresh(errorMsgJPA); assertEquals(T_NEW_MULTI_HOP, errorMsgJPA.usesMultiHop()); }