@Test
public void testReadWriteFilterRecord() throws Exception {

    final GuavaBloomFilter filter = new GuavaBloomFilter(
            expectedInsertions,
            fpp,
            creation,
            expiration,
            validPeriodAfterAccess);
    final FilterRecord<GuavaBloomFilter> record = new FilterRecord<>(testingFilterName, filter);
    final FileChannel channel = FileChannel.open(tempFile.toPath(), StandardOpenOption.CREATE, StandardOpenOption.WRITE, StandardOpenOption.READ);
    record.writeFullyTo(channel);
    final FilterRecordInputStream<GuavaBloomFilter> stream = new FilterRecordInputStream<>(tempFile.toPath(), new GuavaBloomFilterFactory());
    assertThat(stream.nextFilterRecord()).isEqualTo(new FilterRecord<>(testingFilterName, filter));
}