@Test
public void getBranchWithRecordTest() {

    try (RepositoryConnection conn = repo.getConnection()) {
        VersionedRDFRecord record = versionedRDFRecordFactory.createNew(VERSIONED_RDF_RECORD_IRI);
        record.setBranch(Collections.singleton(branchFactory.createNew(BRANCH_IRI)));
        Branch branch = service.getBranch(record, BRANCH_IRI, branchFactory, conn);
        assertFalse(branch.getModel().isEmpty());
        assertEquals(BRANCH_IRI, branch.getResource());
    }
}