#NEWLINE# def __init__( self , port , network ) : #NEWLINE# #INDENT# self . _port = port #NEWLINE# self . _network = self #NEWLINE# self . _plugin = mock . Mock ( ) #NEWLINE# self . _plugin_context = mock . Mock ( ) #NEWLINE# self . _plugin . get_ports . return_value = [ ] #NEWLINE# if network . network_segments : #NEWLINE# #INDENT# self . _bound_segment = network . network_segments [ 0 ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# self . _bound_segment = None