@Test
public void test8Update() {

	VXPortalUser vxPUserExp = CreateVXPortalUser();
	vxPUserExp.setLoginId(loginId);
	XXPortalUser xxPUserExp = new XXPortalUser();
	xxPUserExp.setLoginId(loginId);
	XXPortalUserDao xxPortalUserDao = Mockito.mock(XXPortalUserDao.class);
	Mockito.when(daoManager.getXXPortalUser()).thenReturn(xxPortalUserDao);
	Mockito.when(xxPortalUserDao.getById(Mockito.anyLong())).thenReturn(xxPUserExp);
	Mockito.doNothing().when(userManager).checkAccess(xxPUserExp);
	Mockito.doNothing().when(msRestUtil).validateVUserProfileForUpdate(xxPUserExp, vxPUserExp);
	Mockito.when(userManager.updateUser(vxPUserExp)).thenReturn(xxPUserExp);
	Mockito.when(userManager.mapXXPortalUserVXPortalUser(xxPUserExp)).thenReturn(vxPUserExp);
	VXPortalUser vxPUserAct = userREST.update(vxPUserExp, request);
	Assert.assertNotNull(vxPUserAct);
	Assert.assertEquals(xxPUserExp.getLoginId(), vxPUserAct.getLoginId());
	Assert.assertEquals(vxPUserExp.getId(), vxPUserAct.getId());
	Assert.assertEquals(vxPUserExp.getFirstName(), vxPUserAct.getFirstName());
	Mockito.verify(daoManager).getXXPortalUser();
	Mockito.verify(xxPortalUserDao).getById(Mockito.anyLong());
	Mockito.verify(userManager).checkAccess(xxPUserExp);
	Mockito.verify(msRestUtil).validateVUserProfileForUpdate(xxPUserExp, vxPUserExp);
	Mockito.verify(userManager).updateUser(vxPUserExp);
	Mockito.verify(userManager).mapXXPortalUserVXPortalUser(xxPUserExp);
}