@Test
public void testGetDifferenceChainCommonParent() {

    // Setup:
    List<Resource> commitChain = Stream.of(VALUE_FACTORY.createIRI("http://mobi.com/test/commits#test0"),
            VALUE_FACTORY.createIRI("http://mobi.com/test/commits#test1"),
            VALUE_FACTORY.createIRI("http://mobi.com/test/commits#test2"),
            VALUE_FACTORY.createIRI("http://mobi.com/test/commits#test4b")).collect(Collectors.toList());
    Resource sourceId = VALUE_FACTORY.createIRI("http://mobi.com/test/commits#test4b");
    Resource targetId = VALUE_FACTORY.createIRI("http://mobi.com/test/commits#testLoner");
    // Expected should contain all commits from the source chain
    Collections.reverse(commitChain);
    try (RepositoryConnection conn = repo.getConnection()) {
        List<Resource> actual = service.getDifferenceChain(sourceId, targetId, conn);
        assertEquals(actual, commitChain);
    }
}