use of com.amplifyframework.rx.RxAdapters.VoidBehaviors in project amplify-android by aws-amplify.
the class RxAdaptersTest method completableIsDisposable.
/**
* The {@link Completable} returned by
* {@link VoidBehaviors#toCompletable(VoidBehaviors.ActionEmitter)}
* is cancelable.
*/
// No-op VoidResultEmitter body
@SuppressWarnings("checkstyle:WhitespaceAround")
@Test
public void completableIsDisposable() {
Completable completable = VoidBehaviors.toCompletable(((onResult, onError) -> {
}));
TestObserver<?> observer = completable.test();
observer.dispose();
assertTrue(observer.isDisposed());
}
Aggregations