#NEWLINE# def test_multidigraph_weighted( self ) : #NEWLINE# #INDENT# edges = [ ( 0 , 1 , 10 ) , ( 0 , 1 , 10 ) , ( 1 , 2 , 1 ) , ( 2 , 3 , 1 ) , ( 3 , 2 , 10 ) , ( 3 , 2 , 1 ) , ( 2 , 1 , 10 ) , ( 2 , 1 , 1 ) ] #NEWLINE# G = nx . MultiDiGraph ( ) #NEWLINE# G . add_weighted_edges_from ( self ) #NEWLINE# cells = nx . voronoi_cells ( G , { 0 , 3 } ) #NEWLINE# expected = { #NEWLINE# #INDENT# 0 : { 0 } , #NEWLINE# 3 : { 1 , 2 , 3 } , #NEWLINE# #UNINDENT# } #NEWLINE# assert_equal ( expected , cells )