Interface CommonTestKitOps<S,P>

All Superinterfaces:
ClearOps, PolicyOpsTestKit<P>
All Known Subinterfaces:
PersistenceTestKitOps<S,P>
All Known Implementing Classes:
PersistenceTestKit, SnapshotTestKit

public interface CommonTestKitOps<S,P> extends ClearOps, PolicyOpsTestKit<P>
  • Method Summary

    Modifier and Type
    Method
    Description
    <A> A
    expectNextPersisted(String persistenceId, A event)
    Check that event has been saved in the storage.
    <A> A
    expectNextPersisted(String persistenceId, A event, scala.concurrent.duration.FiniteDuration max)
    Check for max time that event has been saved in the storage.
    void
    Check that nothing has been saved in the storage.
    void
    expectNothingPersisted(String persistenceId, scala.concurrent.duration.FiniteDuration max)
    Check for max time that nothing has been saved in the storage.
    void
    Fail next delete from storage attempt with default exception for any persistence id.
    void
    failNextDelete(String persistenceId)
    Fail next delete from storage attempt with default exception for particular persistence id.
    void
    failNextDelete(String persistenceId, Throwable cause)
    Fail next delete from storage attempt with cause exception for particular persistence id.
    void
    Fail next delete from storage attempt with cause exception for any persistence id.
    void
    Fail next n delete from storage attempts with default exception for any persistence id.
    void
    failNextNDeletes(int n, Throwable cause)
    Fail next n delete from storage attempts with cause exception for any persistence id.
    void
    failNextNDeletes(String persistenceId, int n)
    Fail next n delete from storage attempts with default exception for particular persistence id.
    void
    failNextNDeletes(String persistenceId, int n, Throwable cause)
    Fail next n delete from storage attempts with cause exception for particular persistence id.
    void
    Fail next n write operations with default exception for any persistence id.
    void
    Fail next n write operations with the cause exception for any persistence id.
    void
    failNextNPersisted(String persistenceId, int n)
    Fail next n write operations for particular persistence id.
    void
    failNextNPersisted(String persistenceId, int n, Throwable cause)
    Fail next n write operations with the cause exception for particular persistence id.
    void
    Fail next n read from storage (recovery) attempts with default exception for any persistence id.
    void
    failNextNReads(int n, Throwable cause)
    Fail next n read from storage (recovery) attempts with cause exception for any persistence id.
    void
    failNextNReads(String persistenceId, int n)
    Fail next n read from storage (recovery) attempts with default exception for particular persistence id.
    void
    failNextNReads(String persistenceId, int n, Throwable cause)
    Fail next n read from storage (recovery) attempts with cause exception for particular persistence id.
    void
    Fail next write operation with default exception for any persistence id.
    void
    failNextPersisted(String persistenceId)
    Fail next write operation with default exception for particular persistence id.
    void
    failNextPersisted(String persistenceId, Throwable cause)
    Fail next write operation with cause exception for particular persistence id.
    void
    Fail next write operation with cause exception for any persistence id.
    void
    Fail next read from storage (recovery) attempt with default exception for any persistence id.
    void
    failNextRead(String persistenceId)
    Fail next read from storage (recovery) attempt with default exception for any persistence id.
    void
    failNextRead(String persistenceId, Throwable cause)
    Fail next read from storage (recovery) attempt with cause exception for particular persistence id.
    void
    Fail next read from storage (recovery) attempt with cause exception for any persistence id.

    Methods inherited from interface org.apache.pekko.persistence.testkit.scaladsl.ClearOps

    clearAll, clearByPersistenceId

    Methods inherited from interface org.apache.pekko.persistence.testkit.scaladsl.PolicyOpsTestKit

    failNextNOps, failNextNOps, failNextNOpsCond, failNextNOpsCond, Policies, resetPolicy, withPolicy
  • Method Details

    • expectNextPersisted

      <A> A expectNextPersisted(String persistenceId, A event)
      Check that event has been saved in the storage.
    • expectNextPersisted

      <A> A expectNextPersisted(String persistenceId, A event, scala.concurrent.duration.FiniteDuration max)
      Check for max time that event has been saved in the storage.
    • expectNothingPersisted

      void expectNothingPersisted(String persistenceId)
      Check that nothing has been saved in the storage.
    • expectNothingPersisted

      void expectNothingPersisted(String persistenceId, scala.concurrent.duration.FiniteDuration max)
      Check for max time that nothing has been saved in the storage.
    • failNextDelete

      void failNextDelete(Throwable cause)
      Fail next delete from storage attempt with cause exception for any persistence id.
    • failNextDelete

      void failNextDelete()
      Fail next delete from storage attempt with default exception for any persistence id.
    • failNextDelete

      void failNextDelete(String persistenceId, Throwable cause)
      Fail next delete from storage attempt with cause exception for particular persistence id.
    • failNextDelete

      void failNextDelete(String persistenceId)
      Fail next delete from storage attempt with default exception for particular persistence id.
    • failNextNDeletes

      void failNextNDeletes(int n, Throwable cause)
      Fail next n delete from storage attempts with cause exception for any persistence id.
    • failNextNDeletes

      void failNextNDeletes(int n)
      Fail next n delete from storage attempts with default exception for any persistence id.
    • failNextNDeletes

      void failNextNDeletes(String persistenceId, int n, Throwable cause)
      Fail next n delete from storage attempts with cause exception for particular persistence id.
    • failNextNDeletes

      void failNextNDeletes(String persistenceId, int n)
      Fail next n delete from storage attempts with default exception for particular persistence id.
    • failNextNPersisted

      void failNextNPersisted(String persistenceId, int n, Throwable cause)
      Fail next n write operations with the cause exception for particular persistence id.
    • failNextNPersisted

      void failNextNPersisted(String persistenceId, int n)
      Fail next n write operations for particular persistence id.
    • failNextNPersisted

      void failNextNPersisted(int n, Throwable cause)
      Fail next n write operations with the cause exception for any persistence id.
    • failNextNPersisted

      void failNextNPersisted(int n)
      Fail next n write operations with default exception for any persistence id.
    • failNextNReads

      void failNextNReads(int n, Throwable cause)
      Fail next n read from storage (recovery) attempts with cause exception for any persistence id.
    • failNextNReads

      void failNextNReads(int n)
      Fail next n read from storage (recovery) attempts with default exception for any persistence id.
    • failNextNReads

      void failNextNReads(String persistenceId, int n, Throwable cause)
      Fail next n read from storage (recovery) attempts with cause exception for particular persistence id.
    • failNextNReads

      void failNextNReads(String persistenceId, int n)
      Fail next n read from storage (recovery) attempts with default exception for particular persistence id.
    • failNextPersisted

      void failNextPersisted(String persistenceId, Throwable cause)
      Fail next write operation with cause exception for particular persistence id.
    • failNextPersisted

      void failNextPersisted(String persistenceId)
      Fail next write operation with default exception for particular persistence id.
    • failNextPersisted

      void failNextPersisted(Throwable cause)
      Fail next write operation with cause exception for any persistence id.
    • failNextPersisted

      void failNextPersisted()
      Fail next write operation with default exception for any persistence id.
    • failNextRead

      void failNextRead(Throwable cause)
      Fail next read from storage (recovery) attempt with cause exception for any persistence id.
    • failNextRead

      void failNextRead()
      Fail next read from storage (recovery) attempt with default exception for any persistence id.
    • failNextRead

      void failNextRead(String persistenceId, Throwable cause)
      Fail next read from storage (recovery) attempt with cause exception for particular persistence id.
    • failNextRead

      void failNextRead(String persistenceId)
      Fail next read from storage (recovery) attempt with default exception for any persistence id.