use of com.nytimes.android.external.store.util.Result in project Store by NYTimes.
the class SequentialTest method parallelWithResult.
@Test
public void parallelWithResult() {
BarCode b = new BarCode("one", "two");
Single<Result<Integer>> first = store.getWithResult(b);
Single<Result<Integer>> second = store.getWithResult(b);
first.test().awaitTerminalEvent();
second.test().awaitTerminalEvent();
assertThat(networkCalls).isEqualTo(1);
}