CassandraTimestampStoreInvalidator implements TimestampStoreInvalidator { @Override @Idempotent public long backupAndInvalidate() { backupRunner.ensureTimestampTableExists(); return backupRunner.backupExistingTimestamp(); } @VisibleForTesting  CassandraTimestampStoreInvalidator(CassandraTimestampBackupRunner backupRunner); static CassandraTimestampStoreInvalidator create(KeyValueService keyValueService); @Override @Idempotent long backupAndInvalidate(); @Override @Idempotent void revalidateFromBackup();  }
@Test public void ensuresTablesExistOnInvalidate() { invalidator.backupAndInvalidate(); verify(backupRunner, times(1)).ensureTimestampTableExists(); }
@Test public void backupReturnsTimestampFromBackupRunner() { assertThat(invalidator.backupAndInvalidate()).isEqualTo(BACKUP_TIMESTAMP); verify(backupRunner, times(1)).backupExistingTimestamp(); }