#NEWLINE# def test_create_broadcast_message( self ) : #NEWLINE# #INDENT# self . flags ( max_hop_count = 99 , group = 'cells' ) #NEWLINE# self . flags ( name = 'api-cell' , max_hop_count = 99 , group = 'cells' ) #NEWLINE# method = 'fake_method' #NEWLINE# method_kwargs = dict ( arg1 = 1 , arg2 = 2 ) #NEWLINE# direction = 'down' #NEWLINE# bcast_message = messaging . _BroadcastMessage ( self . msg_runner , self . ctxt , method , method_kwargs , direction ) #NEWLINE# self . assertEqual ( self . ctxt , bcast_message . ctxt ) #NEWLINE# self . assertEqual ( method , bcast_message . method_name ) #NEWLINE# self . assertEqual ( method_kwargs , bcast_message . method_kwargs ) #NEWLINE# self . assertEqual ( direction , bcast_message . direction ) #NEWLINE# self . assertFalse ( bcast_message . fanout ) #NEWLINE# self . assertFalse ( bcast_message . need_response ) #NEWLINE# self . assertEqual ( self . our_name , bcast_message . routing_path ) #NEWLINE# self . assertEqual ( 1 , bcast_message . hop_count ) #NEWLINE# self . assertEqual ( 99 , bcast_message . max_hop_count ) #NEWLINE# self . assertTrue ( bcast_message . is_broadcast ) #NEWLINE# next_hops = bcast_message . _get_next_hops ( ) #NEWLINE# child_cells = self . state_manager . get_child_cells ( ) #NEWLINE# self . assertEqual ( child_cells , next_hops )