@Test
public void testJoinThrows() {

    Observable<String> source = Observable.concat(Observable.just("a"), Observable.<String>error(new RuntimeException("Forced failure")));
    
    Observable<String> result = StringObservable.join(source, ", ");
    
    Observer<Object> observer = mock(Observer.class);
    
    result.subscribe(new TestObserver<Object>(observer));
    
    verify(observer, never()).onNext("a");
    verify(observer, never()).onCompleted();
    verify(observer, times(1)).onError(any(Throwable.class));
}