public final class TestSubscriber<T> extends Object implements org.reactivestreams.Subscriber<T>
| Constructor and Description |
|---|
TestSubscriber() |
| Modifier and Type | Method and Description |
|---|---|
TestSubscriber<T> |
assertCount(Integer expected) |
TestSubscriber<T> |
assertEquals(T expected) |
TestSubscriber<T> |
assertError(Class<? extends Throwable> expected,
String format,
Object... args) |
TestSubscriber<T> |
assertThat(Consumer<T> expectation) |
void |
onComplete() |
void |
onError(Throwable t) |
void |
onNext(T t) |
void |
onSubscribe(org.reactivestreams.Subscription s) |
TestSubscriber<T> |
setPerformanceCallback(Consumer<Tuple2<Long,Long>> performanceCallback) |
TestSubscriber<T> |
setPerformanceLoggerName(Supplier<String> name) |
TestSubscriber<T> |
setScanningCallback(Consumer<org.reactivestreams.Subscription> scanningCallback) |
TestSubscriber<T> |
setScanningLoggerName(Supplier<String> name) |
void |
verify(long timeout,
TimeUnit unit) |
public TestSubscriber<T> assertCount(Integer expected)
public TestSubscriber<T> assertEquals(T expected)
public TestSubscriber<T> assertError(Class<? extends Throwable> expected, String format, Object... args)
public TestSubscriber<T> assertThat(Consumer<T> expectation)
public void onComplete()
onComplete in interface org.reactivestreams.Subscriber<T>public void onError(Throwable t)
onError in interface org.reactivestreams.Subscriber<T>public void onSubscribe(org.reactivestreams.Subscription s)
onSubscribe in interface org.reactivestreams.Subscriber<T>public TestSubscriber<T> setPerformanceCallback(Consumer<Tuple2<Long,Long>> performanceCallback)
public TestSubscriber<T> setPerformanceLoggerName(Supplier<String> name)
public TestSubscriber<T> setScanningCallback(Consumer<org.reactivestreams.Subscription> scanningCallback)
public TestSubscriber<T> setScanningLoggerName(Supplier<String> name)
public void verify(long timeout,
TimeUnit unit)
throws InterruptedException
InterruptedExceptionCopyright © 2016 Pivotal Software, Inc.. All rights reserved.