#NEWLINE# def test_global_proxy_userpwd_argument( self ) : #NEWLINE# #INDENT# g = build_grab ( ) #NEWLINE# items = [ PROXY1 ] #NEWLINE# g . proxylist . load_list ( items ) #NEWLINE# self . assertEquals ( g . proxylist . get_next_proxy ( ) . username , None ) #NEWLINE# g . proxylist . load_list ( items , proxy_userpwd = 'foo:bar' ) #NEWLINE# proxy = g . proxylist . get_next_proxy ( ) #NEWLINE# self . assertEquals ( proxy . username , 'foo' ) #NEWLINE# self . assertEquals ( proxy . password , 'bar' ) #NEWLINE# items = [ ( PROXY1 + ':admin:test' ) , PROXY2 ] #NEWLINE# g . proxylist . load_list ( items , proxy_userpwd = 'foo:bar' ) #NEWLINE# proxy = g . proxylist . get_next_proxy ( ) #NEWLINE# self . assertEquals ( proxy . username , 'admin' ) #NEWLINE# self . assertEquals ( proxy . password , 'test' )