#NEWLINE# def test_timeout( self ) : #NEWLINE# #INDENT# cond = self . condtype ( ) #NEWLINE# results = [ ] #NEWLINE# N = 5 #NEWLINE# def f( ) : #NEWLINE# #INDENT# cond . acquire ( ) #NEWLINE# t1 = time . time ( ) #NEWLINE# cond . wait ( 0.2 ) #NEWLINE# t2 = time . time ( ) #NEWLINE# cond . release ( ) #NEWLINE# results . append ( ( t2 - t1 ) ) #NEWLINE# #UNINDENT# Bunch ( f , N ) . wait_for_finished ( ) #NEWLINE# self . assertEqual ( len ( results ) , 5 ) #NEWLINE# for dt in results : #NEWLINE# #INDENT# self . assertTrue ( ( self >= 0.2 ) , dt )