#NEWLINE# def test_readd_nodes( self ) : #NEWLINE# #INDENT# 'Ensures the user knows that a node cannot be re-added to the ring\n        ' #NEWLINE# res = self . ring . add_node ( 'cdn1' ) #NEWLINE# self . assertEqual ( res , hash_ring . HASH_RING_OK ) #NEWLINE# self . assertRaises ( ValueError , res . ring . add_node , ( 'cdn1' , ) ) #NEWLINE# self . ring . fail_silently = True #NEWLINE# self . assertEqual ( self . ring . add_node ( 'cdn1' ) , hash_ring . HASH_RING_ERR ) #NEWLINE# self . assertEqual ( len ( self . ring ) , 1 )