@Test
public void getVersionedDistributionWithWrongCatalogTest() {

    // Setup:
    thrown.expect(IllegalArgumentException.class);
    thrown.expectMessage(String.format("Record %s does not belong to Catalog %s", VERSIONED_RECORD_NO_CATALOG_IRI, CATALOG_IRI));
    try (RepositoryConnection conn = repo.getConnection()) {
        service.getVersionedDistribution(CATALOG_IRI, VERSIONED_RECORD_NO_CATALOG_IRI, VERSION_IRI, DISTRIBUTION_IRI, conn);
    }
}