Package org.reactivestreams.tck.flow
Class FlowPublisherVerification<T>
- java.lang.Object
-
- org.reactivestreams.tck.PublisherVerification<T>
-
- org.reactivestreams.tck.flow.FlowPublisherVerification<T>
-
- All Implemented Interfaces:
PublisherVerificationRules
public abstract class FlowPublisherVerification<T> extends PublisherVerification<T>
Provides tests for verifying a Java 9+Flow.Publisher
specification rules.- See Also:
Flow.Publisher
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.reactivestreams.tck.PublisherVerification
PublisherVerification.PublisherTestRun<T>
-
-
Field Summary
-
Fields inherited from class org.reactivestreams.tck.PublisherVerification
SKIPPING_NO_ERROR_PUBLISHER_AVAILABLE, SKIPPING_OPTIONAL_TEST_FAILED
-
-
Constructor Summary
Constructors Constructor Description FlowPublisherVerification(TestEnvironment env)
FlowPublisherVerification(TestEnvironment env, long publisherReferenceGCTimeoutMillis)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract java.util.concurrent.Flow.Publisher<T>
createFailedFlowPublisher()
By implementing this method, additional TCK tests concerning a "failed" publishers will be run.Publisher<T>
createFailedPublisher()
By implementing this method, additional TCK tests concerning a "failed" publishers will be run.abstract java.util.concurrent.Flow.Publisher<T>
createFlowPublisher(long elements)
This is the main method you must implement in your test incarnation.Publisher<T>
createPublisher(long elements)
This is the main method you must implement in your test incarnation.-
Methods inherited from class org.reactivestreams.tck.PublisherVerification
activePublisherTest, boundedDepthOfOnNextAndRequestRecursion, envPublisherReferenceGCTimeoutMillis, maxElementsFromPublisher, notVerified, notVerified, optional_spec104_mustSignalOnErrorWhenFails, optional_spec105_emptyStreamMustTerminateBySignallingOnComplete, optional_spec111_maySupportMultiSubscribe, optional_spec111_multicast_mustProduceTheSameElementsInTheSameSequenceToAllOfItsSubscribersWhenRequestingManyUpfront, optional_spec111_multicast_mustProduceTheSameElementsInTheSameSequenceToAllOfItsSubscribersWhenRequestingManyUpfrontAndCompleteAsExpected, optional_spec111_multicast_mustProduceTheSameElementsInTheSameSequenceToAllOfItsSubscribersWhenRequestingOneByOne, optional_spec111_registeredSubscribersMustReceiveOnNextOrOnCompleteSignals, optional_spec309_requestNegativeNumberMaySignalIllegalArgumentExceptionWithSpecificMessage, optionalActivePublisherTest, potentiallyPendingTest, potentiallyPendingTest, publisherUnableToSignalOnComplete, required_createPublisher1MustProduceAStreamOfExactly1Element, required_createPublisher3MustProduceAStreamOfExactly3Elements, required_spec101_subscriptionRequestMustResultInTheCorrectNumberOfProducedElements, required_spec102_maySignalLessThanRequestedAndTerminateSubscription, required_spec105_mustSignalOnCompleteWhenFiniteStreamTerminates, required_spec107_mustNotEmitFurtherSignalsOnceOnCompleteHasBeenSignalled, required_spec109_mayRejectCallsToSubscribeIfPublisherIsUnableOrUnwillingToServeThemRejectionMustTriggerOnErrorAfterOnSubscribe, required_spec109_mustIssueOnSubscribeForNonNullSubscriber, required_spec109_subscribeThrowNPEOnNullSubscriber, required_spec302_mustAllowSynchronousRequestCallsFromOnNextAndOnSubscribe, required_spec303_mustNotAllowUnboundedRecursion, required_spec306_afterSubscriptionIsCancelledRequestMustBeNops, required_spec307_afterSubscriptionIsCancelledAdditionalCancelationsMustBeNops, required_spec309_requestNegativeNumberMustSignalIllegalArgumentException, required_spec309_requestZeroMustSignalIllegalArgumentException, required_spec312_cancelMustMakeThePublisherToEventuallyStopSignaling, required_spec313_cancelMustMakeThePublisherEventuallyDropAllReferencesToTheSubscriber, required_spec317_mustNotSignalOnErrorWhenPendingAboveLongMaxValue, required_spec317_mustSupportACumulativePendingElementCountUpToLongMaxValue, required_spec317_mustSupportAPendingElementCountUpToLongMaxValue, required_validate_boundedDepthOfOnNextAndRequestRecursion, required_validate_maxElementsFromPublisher, setUp, skipStochasticTests, stochastic_spec103_mustSignalOnMethodsSequentially, stochasticTest, untested_spec106_mustConsiderSubscriptionCancelledAfterOnErrorOrOnCompleteHasBeenCalled, untested_spec107_mustNotEmitFurtherSignalsOnceOnErrorHasBeenSignalled, untested_spec108_possiblyCanceledSubscriptionShouldNotReceiveOnErrorOrOnCompleteSignals, untested_spec109_subscribeShouldNotThrowNonFatalThrowable, untested_spec110_rejectASubscriptionRequestIfTheSameSubscriberSubscribesTwice, untested_spec304_requestShouldNotPerformHeavyComputations, untested_spec305_cancelMustNotSynchronouslyPerformHeavyComputation, whenHasErrorPublisherTest
-
-
-
-
Constructor Detail
-
FlowPublisherVerification
public FlowPublisherVerification(TestEnvironment env, long publisherReferenceGCTimeoutMillis)
-
FlowPublisherVerification
public FlowPublisherVerification(TestEnvironment env)
-
-
Method Detail
-
createPublisher
public final Publisher<T> createPublisher(long elements)
Description copied from class:PublisherVerification
This is the main method you must implement in your test incarnation. It must create a Publisher for a stream with exactly the given number of elements. If `elements` is `Long.MAX_VALUE` the produced stream must be infinite.- Specified by:
createPublisher
in classPublisherVerification<T>
-
createFlowPublisher
public abstract java.util.concurrent.Flow.Publisher<T> createFlowPublisher(long elements)
This is the main method you must implement in your test incarnation. It must create a Publisher for a stream with exactly the given number of elements. If `elements` is `Long.MAX_VALUE` the produced stream must be infinite.
-
createFailedPublisher
public final Publisher<T> createFailedPublisher()
Description copied from class:PublisherVerification
By implementing this method, additional TCK tests concerning a "failed" publishers will be run. The expected behaviour of thePublisher
returned by this method is hand out a subscription, followed by signallingonError
on it, as specified by Rule 1.9. If you ignore these additional tests, returnnull
from this method.- Specified by:
createFailedPublisher
in classPublisherVerification<T>
-
createFailedFlowPublisher
public abstract java.util.concurrent.Flow.Publisher<T> createFailedFlowPublisher()
By implementing this method, additional TCK tests concerning a "failed" publishers will be run. The expected behaviour of theFlow.Publisher
returned by this method is hand out a subscription, followed by signallingonError
on it, as specified by Rule 1.9. If you ignore these additional tests, returnnull
from this method.
-
-