#NEWLINE# def test_verifies_that_node_will_reuse_its_ip_address( self ) : #NEWLINE# #INDENT# ip_range = models . IPAddrRange ( first = '10.10.0.3' , last = '10.10.0.9' ) #NEWLINE# self . admin_ng . ip_ranges . append ( ip_range ) #NEWLINE# db ( ) . flush ( ) #NEWLINE# manager . NetworkManager . assign_admin_ips ( self . env . nodes ) #NEWLINE# for node in self . reuse_nodes : #NEWLINE# #INDENT# self . assertEqual ( len ( node . ip_addrs ) , 1 ) #NEWLINE# ip = node . ip_addrs [ 0 ] #NEWLINE# self . assertEqual ( node . ip , ip . ip_addr ) #NEWLINE# #UNINDENT# self . assertEqual ( len ( self . assign_from_new . ip_addrs ) , 1 ) #NEWLINE# ip = node . assign_from_new . ip_addrs [ 0 ] #NEWLINE# self . assertEqual ( ip . ip_addr , '10.10.0.5' )