@Test
public void testUpdateGroup() {

    Group newGroup = groupFactory.createNew(VALUE_FACTORY.createIRI(groupId1));
    engine.updateGroup(newGroup);
    Model groupModel = MODEL_FACTORY.createModel();
    RepositoryConnection connection = repo.getConnection();
    RepositoryResult<Statement> statements = connection.getStatements(VALUE_FACTORY.createIRI(groupId1), null, null);
    statements.forEach(groupModel::add);
    connection.close();
    assertFalse(groupModel.isEmpty());
    Optional<Group> optGroup = groupFactory.getExisting(VALUE_FACTORY.createIRI(groupId1), groupModel);
    assertTrue(optGroup.isPresent());
    Group savedGroup = optGroup.get();
    assertTrue(savedGroup.getMember().isEmpty());
}