Class FlowSubscriberBlackboxVerification<T>

  • All Implemented Interfaces:
    org.reactivestreams.tck.flow.support.SubscriberBlackboxVerificationRules

    public abstract class FlowSubscriberBlackboxVerification<T>
    extends org.reactivestreams.tck.SubscriberBlackboxVerification<T>
    implements org.reactivestreams.tck.flow.support.SubscriberBlackboxVerificationRules
    Provides tests for verifying Flow.Subscriber and Flow.Subscription specification rules, without any modifications to the tested implementation (also known as "Black Box" testing). This verification is NOT able to check many of the rules of the spec, and if you want more verification of your implementation you'll have to implement org.reactivestreams.tck.SubscriberWhiteboxVerification instead.
    See Also:
    Flow.Subscriber, Flow.Subscription
    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.reactivestreams.tck.SubscriberBlackboxVerification

        org.reactivestreams.tck.SubscriberBlackboxVerification.BlackboxTestStage
    • Field Summary

      • Fields inherited from class org.reactivestreams.tck.SubscriberBlackboxVerification

        env
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      abstract java.util.concurrent.Flow.Subscriber<T> createFlowSubscriber()
      This is the main method you must implement in your test incarnation.
      org.reactivestreams.Subscriber<T> createSubscriber()  
      void triggerFlowRequest​(java.util.concurrent.Flow.Subscriber<? super T> subscriber)
      Override this method if the Flow.Subscriber implementation you are verifying needs an external signal before it signals demand to its Publisher.
      void triggerRequest​(org.reactivestreams.Subscriber<? super T> subscriber)  
      • Methods inherited from class org.reactivestreams.tck.SubscriberBlackboxVerification

        blackboxSubscriberTest, blackboxSubscriberWithoutSetupTest, notVerified, publisherExecutorService, required_spec201_blackbox_mustSignalDemandViaSubscriptionRequest, required_spec203_blackbox_mustNotCallMethodsOnSubscriptionOrPublisherInOnComplete, required_spec203_blackbox_mustNotCallMethodsOnSubscriptionOrPublisherInOnError, required_spec205_blackbox_mustCallSubscriptionCancelIfItAlreadyHasAnSubscriptionAndReceivesAnotherOnSubscribeSignal, required_spec209_blackbox_mustBePreparedToReceiveAnOnCompleteSignalWithoutPrecedingRequestCall, required_spec209_blackbox_mustBePreparedToReceiveAnOnCompleteSignalWithPrecedingRequestCall, required_spec210_blackbox_mustBePreparedToReceiveAnOnErrorSignalWithoutPrecedingRequestCall, required_spec210_blackbox_mustBePreparedToReceiveAnOnErrorSignalWithPrecedingRequestCall, required_spec213_blackbox_onError_mustThrowNullPointerExceptionWhenParametersAreNull, required_spec213_blackbox_onNext_mustThrowNullPointerExceptionWhenParametersAreNull, required_spec213_blackbox_onSubscribe_mustThrowNullPointerExceptionWhenParametersAreNull, setUp, shutdownPublisherExecutorService, startPublisherExecutorService, untested_spec202_blackbox_shouldAsynchronouslyDispatch, untested_spec204_blackbox_mustConsiderTheSubscriptionAsCancelledInAfterRecievingOnCompleteOrOnError, untested_spec206_blackbox_mustCallSubscriptionCancelIfItIsNoLongerValid, untested_spec207_blackbox_mustEnsureAllCallsOnItsSubscriptionTakePlaceFromTheSameThreadOrTakeCareOfSynchronization, untested_spec208_blackbox_mustBePreparedToReceiveOnNextSignalsAfterHavingCalledSubscriptionCancel, untested_spec211_blackbox_mustMakeSureThatAllCallsOnItsMethodsHappenBeforeTheProcessingOfTheRespectiveEvents, untested_spec212_blackbox_mustNotCallOnSubscribeMoreThanOnceBasedOnObjectEquality, untested_spec213_blackbox_failingOnSignalInvocation, untested_spec301_blackbox_mustNotBeCalledOutsideSubscriberContext, untested_spec308_blackbox_requestMustRegisterGivenNumberElementsToBeProduced, untested_spec310_blackbox_requestMaySynchronouslyCallOnNextOnSubscriber, untested_spec311_blackbox_requestMaySynchronouslyCallOnCompleteOrOnError, untested_spec314_blackbox_cancelMayCauseThePublisherToShutdownIfNoOtherSubscriptionExists, untested_spec315_blackbox_cancelMustNotThrowExceptionAndMustSignalOnError, untested_spec316_blackbox_requestMustNotThrowExceptionAndMustOnErrorTheSubscriber
      • Methods inherited from class org.reactivestreams.tck.WithHelperPublisher

        createElement, createHelperPublisher
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface org.reactivestreams.tck.flow.support.SubscriberBlackboxVerificationRules

        required_spec201_blackbox_mustSignalDemandViaSubscriptionRequest, required_spec203_blackbox_mustNotCallMethodsOnSubscriptionOrPublisherInOnComplete, required_spec203_blackbox_mustNotCallMethodsOnSubscriptionOrPublisherInOnError, required_spec205_blackbox_mustCallSubscriptionCancelIfItAlreadyHasAnSubscriptionAndReceivesAnotherOnSubscribeSignal, required_spec209_blackbox_mustBePreparedToReceiveAnOnCompleteSignalWithoutPrecedingRequestCall, required_spec209_blackbox_mustBePreparedToReceiveAnOnCompleteSignalWithPrecedingRequestCall, required_spec210_blackbox_mustBePreparedToReceiveAnOnErrorSignalWithoutPrecedingRequestCall, required_spec210_blackbox_mustBePreparedToReceiveAnOnErrorSignalWithPrecedingRequestCall, required_spec213_blackbox_onError_mustThrowNullPointerExceptionWhenParametersAreNull, required_spec213_blackbox_onNext_mustThrowNullPointerExceptionWhenParametersAreNull, required_spec213_blackbox_onSubscribe_mustThrowNullPointerExceptionWhenParametersAreNull, untested_spec202_blackbox_shouldAsynchronouslyDispatch, untested_spec204_blackbox_mustConsiderTheSubscriptionAsCancelledInAfterRecievingOnCompleteOrOnError, untested_spec206_blackbox_mustCallSubscriptionCancelIfItIsNoLongerValid, untested_spec207_blackbox_mustEnsureAllCallsOnItsSubscriptionTakePlaceFromTheSameThreadOrTakeCareOfSynchronization, untested_spec208_blackbox_mustBePreparedToReceiveOnNextSignalsAfterHavingCalledSubscriptionCancel, untested_spec211_blackbox_mustMakeSureThatAllCallsOnItsMethodsHappenBeforeTheProcessingOfTheRespectiveEvents, untested_spec212_blackbox_mustNotCallOnSubscribeMoreThanOnceBasedOnObjectEquality, untested_spec213_blackbox_failingOnSignalInvocation, untested_spec301_blackbox_mustNotBeCalledOutsideSubscriberContext, untested_spec308_blackbox_requestMustRegisterGivenNumberElementsToBeProduced, untested_spec310_blackbox_requestMaySynchronouslyCallOnNextOnSubscriber, untested_spec311_blackbox_requestMaySynchronouslyCallOnCompleteOrOnError, untested_spec314_blackbox_cancelMayCauseThePublisherToShutdownIfNoOtherSubscriptionExists, untested_spec315_blackbox_cancelMustNotThrowExceptionAndMustSignalOnError, untested_spec316_blackbox_requestMustNotThrowExceptionAndMustOnErrorTheSubscriber
    • Method Detail

      • triggerRequest

        public final void triggerRequest​(org.reactivestreams.Subscriber<? super T> subscriber)
        Overrides:
        triggerRequest in class org.reactivestreams.tck.SubscriberBlackboxVerification<T>
      • triggerFlowRequest

        public void triggerFlowRequest​(java.util.concurrent.Flow.Subscriber<? super T> subscriber)
        Override this method if the Flow.Subscriber implementation you are verifying needs an external signal before it signals demand to its Publisher. By default this method does nothing.
      • createSubscriber

        public final org.reactivestreams.Subscriber<T> createSubscriber()
        Specified by:
        createSubscriber in class org.reactivestreams.tck.SubscriberBlackboxVerification<T>
      • createFlowSubscriber

        public abstract java.util.concurrent.Flow.Subscriber<T> createFlowSubscriber()
        This is the main method you must implement in your test incarnation. It must create a new Flow.Subscriber instance to be subjected to the testing logic.