Interface PolicyOpsTestKit<P>
- All Known Subinterfaces:
CommonTestKitOps<S,,P> PersistenceTestKitOps<S,P>
- All Known Implementing Classes:
PersistenceTestKit,SnapshotTestKit
public interface PolicyOpsTestKit<P>
-
Method Summary
Modifier and TypeMethodDescriptionvoidfailNextNOps(int n) Fail n following journal operations regardless of their type.voidfailNextNOps(int n, Throwable cause) Failnfollowing journal operations regardless of their type.voidfailNextNOpsCond(scala.Function2<String, P, Object> cond, int n) Failnfollowing journal operations depending on the conditioncond.voidfailNextNOpsCond(scala.Function2<String, P, Object> cond, int n, Throwable cause) Failnfollowing journal operations depending on the conditioncond.Policies()voidReturns default policy if it was changed by {@link PolicyOpsTestKit.this.withPolicy()}.withPolicy(ProcessingPolicy<P> policy) Set new processing policy for journal operations.
-
Method Details
-
Policies
ProcessingPolicy.DefaultPolicies<P> Policies() -
failNextNOps
void failNextNOps(int n) Fail n following journal operations regardless of their type. Fails operations with defaultExpectedFailureexception. -
failNextNOps
Failnfollowing journal operations regardless of their type. Fails operations with thecauseexception. -
failNextNOpsCond
Failnfollowing journal operations depending on the conditioncond. Failure triggers, whencondreturns true. Fails operations with defaultExpectedFailureexception. -
failNextNOpsCond
Failnfollowing journal operations depending on the conditioncond. Failure triggers, whencondreturns true. Fails operations with thecauseexception. -
resetPolicy
void resetPolicy()Returns default policy if it was changed by {@link PolicyOpsTestKit.this.withPolicy()}. -
withPolicy
Set new processing policy for journal operations. NOTE! Overrides previously invokedfailNext...orrejectNext...
-