#NEWLINE# def test_when_worker_did_not_receive_first_chunk_for_10_secs_it_should_be_available_again( self ) : #NEWLINE# #INDENT# messages1 = [ { #NEWLINE# #INDENT# 'worker' : self . make_heartbeat_request ( 'tcp://127.0.0.1:1' , 'en-GB' , 'STARTED' ) , #NEWLINE# #UNINDENT# } , { #NEWLINE# #INDENT# 'frontend' : self . make_frontend_request ( ) , #NEWLINE# #UNINDENT# } ] #NEWLINE# messages2 = ( [ { #NEWLINE# #INDENT# 'worker' : self . make_heartbeat_request ( 'tcp://127.0.0.1:1' , 'en-GB' , 'WAITING' ) , #NEWLINE# #UNINDENT# } ] * 10 ) #NEWLINE# messages3 = [ { #NEWLINE# #INDENT# 'frontend' : self . make_frontend_request ( ) , #NEWLINE# #UNINDENT# } ] #NEWLINE# self . run_master ( ( ( self + messages2 ) + messages3 ) ) #NEWLINE# expected_message = self . make_frontend_successfull_response ( 'tcp://127.0.0.1:1' ) #NEWLINE# self . assertThatMessagesWereSendToFrontend ( [ expected_message , expected_message ] )