question: public final TestSubscriber assertTerminated ( ) { if ( done . getCount ( ) != 0 ) { fail ( "" , "Subscriber still running!" , errors ) ; } long c = completions ; if ( c > 1 ) { fail ( "" , "Terminated with multiple completions: " + c , errors ) ; } int s = errors . size ( ) ; if ( s > 1 ) { fail ( "" , "Terminated with multiple errors: " + s , errors ) ; } if ( c != 0 && s != 0 ) { fail ( "" , "Terminated with multiple completions and errors: " + c , errors ) ; } return this ; }
target:  Assert that the TestSubscriber terminated (i.e., the terminal latch reached zero).