@Test
public void commitWithChangesWithRepoConnToVersionedRDFRecordTest() throws Exception {

    // Setup:
    Model additions = MODEL_FACTORY.createModel();
    Model deletions = MODEL_FACTORY.createModel();
    Resource result = manager.commit(CATALOG_IRI, record.getResource(), targetBranch.getResource(), user, "Message", additions, deletions, repo.getConnection());
    assertEquals(commit.getResource(), result);
    verify(catalogUtils).getRecord(eq(CATALOG_IRI), eq(record.getResource()), eq(versionedRDFRecordFactory), any(RepositoryConnection.class));
    verify(baseService).getTargetBranch(eq(record), eq(targetBranch.getResource()), any(RepositoryConnection.class));
    verify(baseService).getBranchHeadCommit(eq(targetBranch), any(RepositoryConnection.class));
    verify(baseService).addCommit(eq(targetBranch), eq(user), eq("Message"), eq(additions), eq(deletions), eq(commit), eq(null), any(RepositoryConnection.class));
}