= Observable.from(actual);
final List<Integer> expect = new ArrayList<>(actual.length);
observable.subscribe(new Subscriber<Integer>() {
@Override
public void onCompleted() {}
@Override
public void onError(Throwable e) {}
@Override
public void onNext(Integer integer) {
expect.add(integer);
throw new RuntimeException();
}
});
for (int i = 0, size = expect.size(); i < size; i++) {
assertThat(expect.get(i), is(actual[i]));
}