Search in sources :

Example 1 with StoreCopyServer

use of org.neo4j.com.storecopy.StoreCopyServer in project neo4j by neo4j.

the class BackupImplTest method flushStoreFilesWithCorrectCheckpointTriggerName.

@Test
public void flushStoreFilesWithCorrectCheckpointTriggerName() {
    StoreCopyServer storeCopyServer = mock(StoreCopyServer.class);
    when(storeCopyServer.flushStoresAndStreamStoreFiles(anyString(), any(StoreWriter.class), anyBoolean())).thenReturn(RequestContext.EMPTY);
    BackupImpl backup = new BackupImpl(storeCopyServer, new Monitors(), mock(LogicalTransactionStore.class), mock(TransactionIdStore.class), mock(LogFileInformation.class), defaultStoreIdSupplier(), NullLogProvider.getInstance());
    backup.fullBackup(mock(StoreWriter.class), false).close();
    verify(storeCopyServer).flushStoresAndStreamStoreFiles(eq(BackupImpl.FULL_BACKUP_CHECKPOINT_TRIGGER), any(StoreWriter.class), eq(false));
}
Also used : StoreCopyServer(org.neo4j.com.storecopy.StoreCopyServer) TransactionIdStore(org.neo4j.kernel.impl.transaction.log.TransactionIdStore) StoreWriter(org.neo4j.com.storecopy.StoreWriter) LogFileInformation(org.neo4j.kernel.impl.transaction.log.LogFileInformation) Monitors(org.neo4j.kernel.monitoring.Monitors) LogicalTransactionStore(org.neo4j.kernel.impl.transaction.log.LogicalTransactionStore) Test(org.junit.Test)

Aggregations

Test (org.junit.Test)1 StoreCopyServer (org.neo4j.com.storecopy.StoreCopyServer)1 StoreWriter (org.neo4j.com.storecopy.StoreWriter)1 LogFileInformation (org.neo4j.kernel.impl.transaction.log.LogFileInformation)1 LogicalTransactionStore (org.neo4j.kernel.impl.transaction.log.LogicalTransactionStore)1 TransactionIdStore (org.neo4j.kernel.impl.transaction.log.TransactionIdStore)1 Monitors (org.neo4j.kernel.monitoring.Monitors)1