assertFalse(group.getUsers().contains(user1));
}
private void revertGroup() {
UserGroup group = (UserGroup) getSession().load(UserGroup.class,
groupId);
User user1 = (User) getSession().load(User.class, user1Id);
assertFalse(group.getUsers().contains(user1));
UserDto userDto1 = mapperFacade.map(user1, UserDto.class);
UserGroupDto groupDto = mapperFacade.map(group, UserGroupDto.class);
groupDto.addUser(userDto1);
mapperFacade.map(groupDto, group,
TypeFactory.valueOf(UserGroupDto.class),
TypeFactory.valueOf(UserGroup.class));
assertTrue(group.getUsers().contains(user1));
}