Class RxTestObserver<T>
- java.lang.Object
-
- io.reactivex.rxjava3.observers.BaseTestConsumer<T,io.reactivex.rxjava3.observers.TestObserver<T>>
-
- io.reactivex.rxjava3.observers.TestObserver<T>
-
- org.saynotobugs.confidence.rxjava3.adapters.RxTestObserver<T>
-
- All Implemented Interfaces:
io.reactivex.rxjava3.core.CompletableObserver,io.reactivex.rxjava3.core.MaybeObserver<T>,io.reactivex.rxjava3.core.Observer<T>,io.reactivex.rxjava3.core.SingleObserver<T>,io.reactivex.rxjava3.disposables.Disposable,RxTestAdapter<T>
public final class RxTestObserver<T> extends io.reactivex.rxjava3.observers.TestObserver<T> implements RxTestAdapter<T>
-
-
Constructor Summary
Constructors Constructor Description RxTestObserver()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidack(int count)voidawaitNext(int count)Waits (at most 5 seconds) for at least count values to be emitted.longcompletions()java.lang.Iterable<java.lang.Throwable>errors()booleanisCancelled()java.util.Collection<T>newValues(int count)Returns the next count values that have not been acknowledged so far.-
Methods inherited from class io.reactivex.rxjava3.observers.TestObserver
assertSubscribed, create, create, dispose, hasSubscription, isDisposed, onComplete, onError, onNext, onSubscribe, onSuccess
-
Methods inherited from class io.reactivex.rxjava3.observers.BaseTestConsumer
assertComplete, assertEmpty, assertError, assertError, assertError, assertFailure, assertNoErrors, assertNotComplete, assertNoValues, assertResult, assertValue, assertValue, assertValueAt, assertValueAt, assertValueCount, assertValues, assertValueSequence, assertValuesOnly, await, await, awaitCount, awaitDone, fail, valueAndClass, values, withTag
-
-
-
-
Method Detail
-
completions
public long completions()
- Specified by:
completionsin interfaceRxTestAdapter<T>
-
newValues
public java.util.Collection<T> newValues(int count)
Description copied from interface:RxTestAdapterReturns the next count values that have not been acknowledged so far. The result will have fewer elements if nocountelements have been emitted.- Specified by:
newValuesin interfaceRxTestAdapter<T>
-
awaitNext
public void awaitNext(int count)
Description copied from interface:RxTestAdapterWaits (at most 5 seconds) for at least count values to be emitted. This method returns without an error even if nocounthave been emitted.- Specified by:
awaitNextin interfaceRxTestAdapter<T>
-
ack
public void ack(int count)
- Specified by:
ackin interfaceRxTestAdapter<T>
-
errors
public java.lang.Iterable<java.lang.Throwable> errors()
- Specified by:
errorsin interfaceRxTestAdapter<T>
-
isCancelled
public boolean isCancelled()
- Specified by:
isCancelledin interfaceRxTestAdapter<T>
-
-