#NEWLINE# def wait_for_all_children_respawned( self ) : #NEWLINE# #INDENT# def all_children_active( ) : #NEWLINE# #INDENT# return all ( ( pm . active for pm in self . _child_processes ) ) #NEWLINE# #UNINDENT# for pm in self . _child_processes : #NEWLINE# #INDENT# directory = os . path . dirname ( pm . get_pid_file_name ( ) ) #NEWLINE# self . assertEqual ( 493 , ( os . stat ( directory ) . st_mode & 511 ) ) #NEWLINE# #UNINDENT# max_wait_time = ( cfg . CONF . AGENT . check_child_processes_interval + 5 ) #NEWLINE# utils . wait_until_true ( all_children_active , timeout = max_wait_time , sleep = 0.01 , exception = RuntimeError ( 'Not all children respawned.' ) )