Skip to content

Commit

Permalink
Merge pull request ReactiveX#522 from zsxwing/issue-521
Browse files Browse the repository at this point in the history
Fixed the issue ReactiveX#521
  • Loading branch information
benjchristensen committed Nov 26, 2013
2 parents 8e8b676 + 11c762e commit b35337b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ public void call() {
@Override
public void call() {
wrapped.unsubscribe();
observer.onCompleted();
}
});
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public void testInterval() {
sub.unsubscribe();
scheduler.advanceTimeTo(4, TimeUnit.SECONDS);
verify(observer, never()).onNext(2L);
verify(observer, times(1)).onCompleted();
verify(observer, never()).onCompleted();
verify(observer, never()).onError(any(Throwable.class));
}

Expand Down Expand Up @@ -101,11 +101,11 @@ public void testWithMultipleSubscribersStartingAtSameTime() {
scheduler.advanceTimeTo(4, TimeUnit.SECONDS);

verify(observer, never()).onNext(2L);
verify(observer, times(1)).onCompleted();
verify(observer, never()).onCompleted();
verify(observer, never()).onError(any(Throwable.class));

verify(observer2, never()).onNext(2L);
verify(observer2, times(1)).onCompleted();
verify(observer2, never()).onCompleted();
verify(observer2, never()).onError(any(Throwable.class));
}

Expand Down Expand Up @@ -141,11 +141,11 @@ public void testWithMultipleStaggeredSubscribers() {
sub2.unsubscribe();

inOrder1.verify(observer, never()).onNext(anyLong());
inOrder1.verify(observer, times(1)).onCompleted();
inOrder1.verify(observer, never()).onCompleted();
verify(observer, never()).onError(any(Throwable.class));

inOrder2.verify(observer2, never()).onNext(anyLong());
inOrder2.verify(observer2, times(1)).onCompleted();
inOrder2.verify(observer2, never()).onCompleted();
verify(observer2, never()).onError(any(Throwable.class));
}

Expand Down

0 comments on commit b35337b

Please sign in to comment.