python (3.12.0)

(root)/
lib/
python3.12/
test/
__pycache__/
test_urlparse.cpython-312.pyc

ΑeddlZddlZddlZddlZdZdZdZdZdgfdgfdgfdd	gfd
dgfdd
gfdd
gfddgfdddgfdddgfdgfdgfdgfddgfddgfddgfd dgfd!d"gfd#d$d%gfd&d'd(gfd)d*gfd+d,gfd-d.gfd/d0gfgZ	difdifdifdddgifd
ddgifdddgifdddgifddd1gifdd2gd3gdfddd4d5gifdifdifdifdddgifdddgifdddgifd ddgifd!dd6gifd#d7gd8gd"fd&dd9d:gifd)d;d1gifd+dd<gifd-d=d6gifd/dd>gifgZ
Gd?d@ejZGdAdBejZ
GdCdDejZedEk(rej yy)FNhttp://a/b/c/d;p?q#fhttp://a/b/c/d;p?qhttp://a/b/c/d&z&&=)rrz=a)rar	)r	rza=z&a=br	bza=a+b&b=b+cr	a brb cza=1&a=2r	1r	2&s&&=)rrs=a)rar)rrsa=s&a=brbsa=a+b&b=b+cra brb csa=1&a=2r1r2;a=b);ara=a+b;b=b+c)r		a b;b=b c;a=b);ara=a+b;b=b+c)r	a b;b=b crr
rrrrrrrr!r#r%r'r)c>eZdZdZdZdZdZdZdZdZ	dZ
d	Zd
ZdZ
dZd
ZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZ dZ!d Z"d!Z#d"Z$d#Z%d$Z&d%Z'd&Z(d'Z)d(Z*d)Z+d*Z,d+Z-d,Z.d-Z/d.Z0d/Z1d0Z2d1Z3d2Z4d3Z5y4)5UrlParseTestCasec
tjj|}|j|||j|j
|j|j|j|jf}|j||tjj|}|j|||j||jtjj|j}|j|j|j|j|||j|j|j|j|j
|j
|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j |j tjj#|}|j|||j|j
|j|j|jf}|j||tjj%|}|j|||j||jtjj#|j}|j|j|j|j|||j|j|j|j|j
|j
|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j|j |j yN)urllibparseurlparseassertSequenceEqualschemenetlocpathparamsqueryfragment
urlunparsegeturlassertEqualusernamepasswordhostnameporturlsplit
urlunsplit)selfurlparsedsplitresulttresult2result3s        F/BuggyBox/python/3.12.0/bootstrap/lib/python3.12/test/test_urlparse.pycheckRoundtripsz UrlParseTestCase.checkRoundtripsIs&&s+  0
]]FMM6;;
]]FLL&//
;  F+,,))&1  #.  &--/:,,''

8)6==?;  &16==96==96;;76==96<<8))6??;))6??;))6??;))6??;6;;7&&s+  /
]]FMM6;;
\\6??
,  E*,,))&1  #.  &--/:,,''

8)6==?;  &16==96==96;;76<<8))6??;))6??;))6??;))6??;6;;7rcBtD]\}}tjj|d}|j	||d|z|Dcgc]}t|ds|}}tjj|d}|j	||d|zycc}w)NTkeep_blank_valuesError parsing %rF)parse_qsl_test_casesr.r/	parse_qslr:lenrAorigexpectrEvexpect_without_blankss      rItest_qslzUrlParseTestCase.test_qsl|s0	7LD&\\++DD+IFVV-?$-FG06$D1#ad)Q$D!$D\\++DE+JFV%:.5
7	7%EsBBcNtD]\}}tjj|d}|j	||d|z|Dcic]}t||dr|||}}tjj|d}|j	||d|zycc}w)NTrLrNrF)parse_qs_test_casesr.r/parse_qsr:rRrSs      rItest_qszUrlParseTestCase.test_qss/	7LD&\\**44*HFVV-?$-FG.4%K)*F1IaL8I&'q	\%K!%K\\**45*IFV%:.5
7
	7%KsB"cgd}d}|Dcgc]
}||}}||zD]\}}}|j|||ycc}w)N))zfile:///tmp/junk.txt)filer
/tmp/junk.txtrrr)r^rr_rr)zimap://mail.python.org/mbox1)imapmail.python.org/mbox1rrr)r`rarbrr)z1mms://wms.sys.hinet.net/cts/Drama/09006251100.asf)mmswms.sys.hinet.net/cts/Drama/09006251100.asfrrr)rcrdrerr)znfs://server/path/to/file.txt)nfsserver/path/to/file.txtrrr)rfrgrhrr)z0svn+ssh://svn.zope.org/repos/main/ZConfig/trunk/)svn+sshsvn.zope.org/repos/main/ZConfig/trunk/rrr)rirjrkrr)z)git+ssh://git@github.com/user/project.git)git+sshgit@github.com/user/project.gitrrr)rlrmrnrr)zEitms-services://?action=download-manifest&url=https://example.com/app)
itms-servicesrrr4action=download-manifest&url=https://example.com/appr)rorrrprc||djdtd|dDtd|dDfS)Nrasciic3>K|]}|jdywrrNencode.0xs  rI	<genexpr>zDUrlParseTestCase.test_roundtrips.<locals>._encode.<locals>.<genexpr>:!((7+:rOc3>K|]}|jdywrtrurws  rIrzzDUrlParseTestCase.test_roundtrips.<locals>._encode.<locals>.<genexpr>r{r|rvtuplerFs rI_encodez1UrlParseTestCase.test_roundtrips.<locals>._encode@aDKK(:QqT:::QqT::<
<rrJ)rA	str_casesrrybytes_casesrBrCrDs        rItest_roundtripsz UrlParseTestCase.test_roundtripssY	>	<,55awqz55"+k"9	5C  fe4	56s?cgd}d}|Dcgc]
}||}}d}d}||f}||f}||fD];\}	}
|	D]1}|
D]*\}}
}||z}|f|
z}
|f|z}|j||
|,3=ycc}w)N))z://www.python.org)www.python.orgrrrr)rrrr)z://www.python.org#abc)rrrrabc)rrrr)z://www.python.org?q=abc)rrrq=abcr)rrrr)z://www.python.org/#abc)r/rrr)rrrr)z://a/b/c/d;p?q#f)r	z/b/c/dpqf)r	z/b/c/d;prrc||djdtd|dDtd|dDfS)Nrrrc3>K|]}|jdywrtrurws  rIrzzIUrlParseTestCase.test_http_roundtrips.<locals>._encode.<locals>.<genexpr>r{r|rOc3>K|]}|jdywrtrurws  rIrzzIUrlParseTestCase.test_http_roundtrips.<locals>._encode.<locals>.<genexpr>r{r|r~rrs rIrz6UrlParseTestCase.test_http_roundtrips.<locals>._encoderr)httphttps)httphttpsr)rArrryrstr_schemes
bytes_schemes	str_testsbytes_testsschemes
test_casesr2rBrCrDs               rItest_http_roundtripsz%UrlParseTestCase.test_http_roundtripss	"	<,55awqz55'+
*	#[0$-{#;	=GZ!
=*4=&C 3,C$Y/F#I-E((fe<	=
=	=6sA,c"|||f}|jtjj||||Dcgc]}|j	dc}x}\}}}	|jtjj|||	ycc}w)Nrr)r:r.r/urljoinrv)
rAbaserelurlexpectedstr_componentsrybytes_componentsbasebrelurlb	expectedbs
          rI	checkJoinzUrlParseTestCase.checkJoins1--dF;XF7E8G23AHHW-8G	G45'9--eW=yI8GsBcgd}|Dcgc]}|jd}}||zD]}|jtjj	tjj|||jtjj
tjj||ycc}w)N)Pythonz./Pythonx-newscheme://foo.com/stuffzx://yzx:/yzx:/rrr)rvr:r.r/r@r?r8r0)rArryrus     rItest_unparse_parsez#UrlParseTestCase.test_unparse_parsesb	2;<Qqxx(<<[(	SAV\\44V\\5J5J15MNPQRV\\44V\\5J5J15MNPQR	S=sCc|jtdd|jtdd|jtdd|jtdd|jtdd|jtd	d
|jtdd|jtd
d|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtd d|jtd!d"|jtd#d$|jtd%d$|jtd&d|jtd'd(|jtd)d*|jtd+d,|jtd-d.|jtd/d0|jtd1d"|jtd2d|jtd3d4|jtd5d6y)7Ng:hghttp://a/b/c/g./gg/http://a/b/c/g//g
http://a/g//ghttp://gg?yhttp://a/b/c/g?yg?y/./xhttp://a/b/c/g?y/./x#shttp://a/b/c/d;p?q#sg#shttp://a/b/c/g#sg#s/./xhttp://a/b/c/g#s/./xg?y#shttp://a/b/c/g?y#sg;xhttp://a/b/c/g;xg;x?y#shttp://a/b/c/g;x?y#s.
http://a/b/c/./..http://a/b/../../ghttp://a/b/g../..	http://a/../../../../grrg.http://a/b/c/g..ghttp://a/b/c/.gg..http://a/b/c/g....ghttp://a/b/c/..g./../g./g/.g/./hhttp://a/b/c/g/hg/../hhttp://a/b/c/h)rRFC1808_BASErAs rItest_RFC1808zUrlParseTestCase.test_RFC1808s|UE2|S*:;|U,<=|T+<=|T<8|UJ7|U,>?|Y0FG|T+AB|U,>?|Y0FG|W.BC|U,>?|Y0FG|S/:|T?;|T=9|UM:|V^<|Wk:|X{;|Y=	
|R)?@|T+<=|T+<=|U,>?|U,>?|X~>|W.?@|W.@A|X/?@rcb|jtjjddy)Nzmailto:1337@example.org)mailtorz1337@example.orgrrrr:r.r/r0rs rItest_RFC2368zUrlParseTestCase.test_RFC2368s&../HI>	@rcV|jtdd|jtdd|jtdd|jtdd|jtdd|jtd	d
|jtdd|jtd
d|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd |jtd!d |jtd"d|jtd#t|jtd$d%|jtd&d'|jtd(d)|jtd*d+|jtd,d|jtd-d|jtd.d/|jtd0d1|jtd2d3|jtd4d5|jtd6d7|jtd8d9|jtd:d;|jtd<d=y)>Nrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr	g;x=1/./yhttp://a/b/c/g;x=1/y
g;x=1/../yhttp://a/b/c/yrrg?y/../xhttp://a/b/c/g?y/../xrrg#s/../xhttp://a/b/c/g#s/../x)rRFC2396_BASErs rItest_RFC2396zUrlParseTestCase.test_RFC2396 sJ	
|UE2|S*:;|U,<=|T+<=|T<8|UJ7|U,>?|T+AB|U,>?|W.BC|U,>?|Y0FG|S/:|T?;|T=9|UM:|V^<|Wk:|X{;|Y=|R6|T+<=|T+<=|U,>?|U,>?|X~>|W.?@|W.@A|X/?@|[2HI|\3CD|Y0FG|Z1HI|Y0FG|Z1HIrc@|jtdd|jtdd|jtdd|jtdd|jtdd|jtd	d
|jtdd|jtd
d|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtd d!|jtd"d!|jtd#d$|jtd%d&|jtd'd&|jtd(d|jtd)d|jtd)d|jtd*d|jtd+d|jtd,d|jtd-d.|jtd/d0|jtd1d2|jtd3d4|jtd5d$|jtd6d
|jtd7d8|jtd9d:|jtd;d<|jtd=d>|jtd?d@|jtdAdB|jtdCdD|jtdEdF|jtdGd|jdHddy)IN?yzhttp://a/b/c/d;p?yz;xzhttp://a/b/c/;xrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrz
../../../gz
../../../../gz/./gz/../grrrrrrrrrrrrrrrrrrrrrrrrrrhttp:gzhttp://a/b/c/de)rRFC3986_BASErs rItest_RFC3986zUrlParseTestCase.test_RFC3986Ms|T*>?|T+<=|U51|S)9:|U+;<|T*;<|T,7|U:6|T*>?|U+=>|T*@A|U+=>|W-AB|T*;<|U+=>|Y/EF|R(<=|S9|T/:|T-8|U=9|VN;|W[9|Xk:|Y|<|\<@	
|\,?|_\B|VL9|W\:|T*;<|T*;<|U+=>|U+=>|Xn=|W->?|W-?@|X.>?|[1GH|\2BC|Y/EF|Z0GH|Y/EF|Z0GH|X.>?	
($/@Arc4|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd	|jtd
d|jtdd
|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtdd|jtd d	|jtd!d"|jtd#d$|jtdd|jtdd|jtd%d|jtd&d|jtd'd|jd(dd(|jd)dd|jd)d*d*|jd+d,d-|jd.d,d/|jd0dd1|jd2dd3|jtd4zd5td6z|jd7d8d9|jd:d8d;|jd7d<d=|jd:d<d=|jd7d>d?|jdd8d=|jd@dAdAy)BNrrrhttp:rrrrrrrrrrzhttp://a/b/c/d?yrrrrrrrrrrrrrrrrrrrrrzhttp:?yzhttp:g?yzhttp:g?y/./xzhttp:///rzhttp://a/./gzsvn://pathtorepo/dir1dir2zsvn://pathtorepo/dir2zsvn+ssh://pathtorepo/dir1zsvn+ssh://pathtorepo/dir2zws://a/bzws://a/gz	wss://a/bz	wss://a/grfooz/foozhttp://a/b/c/d/e/z
../../f/g/zhttp://a/b/c/f/g/zhttp://a/b/c/d/ezhttp://a/b/f/g/z/../../f/g/z
http://a/f/g/z	../../f/gzhttp://a/b/c/f/gr	r)rSIMPLE_BASErs rI
test_urljoinszUrlParseTestCase.test_urljoinss{E%0{H-=>{G,<={C(89{E*:;{D):;{D6{E*5{D);<{E*<={I.DE{C8{D9{D7{E-8{F>:{GK8{Il;{H^<{G,=>{G,>?{H-=>{H-=>{G,<={I.@A{J/AB{N3IJz4
3r12HIr>>:.8OP2F<WXz#j1{3{3	
{S(%v1EF	
*L:MN)<9JK*M?K)=/J*K9KL}lOD	
sC%rcgd}d}|Dcgc]
}||}}||zD]O\}}}tjj|}|j|j|j
f||fQgd}|Dcgc]}|j
d}}||zD]1}	|jttjj|	3ycc}wcc}w)N))z http://Test.python.org:5432/foo/test.python.org8)zhttp://12.34.56.78:5432/foo/12.34.56.78r)zhttp://[::1]:5432/foo/::1r)zhttp://[dead:beef::1]:5432/foo/dead:beef::1r)zhttp://[dead:beef::]:5432/foo/dead:beef::r)z:http://[dead:beef:cafe:5417:affe:8FA3:deaf:feed]:5432/foo/'dead:beef:cafe:5417:affe:8fa3:deaf:feedr)z http://[::12.34.56.78]:5432/foo/
::12.34.56.78r)z%http://[::ffff:12.34.56.78]:5432/foo/::ffff:12.34.56.78r)zhttp://Test.python.org/foo/rN)zhttp://12.34.56.78/foo/rN)zhttp://[::1]/foo/rN)zhttp://[dead:beef::1]/foo/rN)zhttp://[dead:beef::]/foo/rN)z5http://[dead:beef:cafe:5417:affe:8FA3:deaf:feed]/foo/rN)zhttp://[::12.34.56.78]/foo/rN)z http://[::ffff:12.34.56.78]/foo/r	N)zhttp://Test.python.org:/foo/rN)zhttp://12.34.56.78:/foo/rN)zhttp://[::1]:/foo/rN)zhttp://[dead:beef::1]:/foo/rN)zhttp://[dead:beef::]:/foo/rN)z6http://[dead:beef:cafe:5417:affe:8FA3:deaf:feed]:/foo/rN)zhttp://[::12.34.56.78]:/foo/rN)z!http://[::ffff:12.34.56.78]:/foo/r	NcZ|djd|djd|dfS)NrrrrOr~rurs rIrz.UrlParseTestCase.test_RFC2732.<locals>._encodes-Q4;;w'1W)=qtCCr)zhttp://::12.34.56.78]/zhttp://[::1/foo/zftp://[::1/foo/bad]/badzhttp://[::1/foo/bad]/badzhttp://[::ffff:12.34.56.78rr)	r.r/r0r:r=r>rvassertRaises
ValueError)
rArrryrrBr=r>	urlparsedinvalid_urls
          rItest_RFC2732zUrlParseTestCase.test_RFC2732s	@	D+45awqz55#,{#:	VC4--c2Ii00)..AXtDTU	V.	3<<Qqxx(<<${2	NKj&,,*?*?M	N6=sC<Ccddddddddtd	d
ftd	dfg
}d}|Dcgc]
}||}}||zD]\}}}tjj	|}|j|j
||j|||f|j|j||j|j|ycc}w)
N)zhttp://python.org#fraghttp://python.orgfrag)rrr)zhttp://python.org/#fraghttp://python.org/r)rrr)zhttp://python.org/?q#fraghttp://python.org/?qr)rrr)zhttp://python.org/p#fragzhttp://python.org/pr)http://python.org/p?qrrrrrc2t|d|DS)Nc3>K|]}|jdywrtrurws  rIrzzCUrlParseTestCase.test_urldefrag.<locals>._encode.<locals>.<genexpr>s8188G,8r|)typers rIrz0UrlParseTestCase.test_urldefrag.<locals>._encodes478a888r)	rrr.r/	urldefragr:r9rBr7)	rArrryrrBdefragrrEs	         rItest_urldefragzUrlParseTestCase.test_urldefragsC:E<I@GB
/5
/4
		9+45awqz55!*[!8	4C\\++C0FV]]_c2Vfd^4VZZ0V__d3	46sC
c`tjjd}|j|jd|j|j
dtjjd}|j|jd|j|j
dy)Nz,http://[FE80::822a:a8ff:fe49:470c%tESt]:1234zfe80::822a:a8ff:fe49:470c%tEStz%[FE80::822a:a8ff:fe49:470c%tESt]:1234s,http://[FE80::822a:a8ff:fe49:470c%tESt]:1234sfe80::822a:a8ff:fe49:470c%tESts%[FE80::822a:a8ff:fe49:470c%tESt]:1234)r.r/r?r:r=r3)rArs  rItest_urlsplit_scoped_IPv6z*UrlParseTestCase.test_urlsplit_scoped_IPv6sLL!!"PQ%EF#JKLL!!"QR%FG#KLrcd}tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|jd|j|jd|j|jd|j|jd|j|jdd|ddd	}tjj|}|j|jd|j|j
d
|j|jd|j|jd|j|jd|j|jd|j|jd
|j|jd|j|jd|j|j|d}tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|jd|j|jd
|j|jd|j|jd|j|j|d}tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|jd|j|jd|j|jd|j|jd|j|jdd|ddd}tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|jd|j|jd|j|jd|j|jd|j|j|d}tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|jd |j|jd|j|jd|j|jd|j|j|d!}tjj|}|jtd"5|jdddy#1swYyxYw)#NzHTTP://WWW.PYTHON.ORG/doc/#fragrzWWW.PYTHON.ORG/doc/rrr7http://User:Pass@www.python.org:080/doc/?query=yes#fragUser:Pass@www.python.org:080	query=yesUserPassPzChttp://User@example.com:Pass@www.python.org:080/doc/?query=yes#frag(User@example.com:Pass@www.python.org:080zUser@example.comsHTTP://WWW.PYTHON.ORG/doc/#fragrsWWW.PYTHON.ORG/doc/rfragwww.python.orgs7http://User:Pass@www.python.org:080/doc/?query=yes#fragUser:Pass@www.python.org:080	query=yesUserPasssChttp://User@example.com:Pass@www.python.org:080/doc/?query=yes#frags(User@example.com:Pass@www.python.org:080sUser@example.coms%HTTP://WWW.PYTHON.ORG:65536/doc/#fragzout of range)r.r/r?r:r2r3r4r6r7r;r<r=r>r9assertRaisesRegexr)rArBrs   rItest_urlsplit_attributesz)UrlParseTestCase.test_urlsplit_attributess/LL!!#&6*#34)"%V,T*T*%56&	
ABQR1GLL!!#&6*#AB)+.V,V,V,%56$S)TLL!!#&6*#MN)+.V,%78V,%56$S)1LL!!#&7+#45*#&W-T*T*%67&ABQR1HLL!!#&7+#BC*,/W-W-W-%67$S)TLL!!#&7+#NO*,/W-%89W-%67$S)7LL!!#&

#
#J
?	
FF			s2
__cd}tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|jd|j|jd|j|jd|j|jd|j|jdd}tjj|}|j|jd	|j|j
d
|j|jd|j|jd|j|jd
|j|jd|j|jd|j|jd
|j|jd|j|jdd}d}tdD]_}tjj||}|j|jd|j|jday)NzQhttp	://www.python
.org	/java
script:	alert('msg
')/?query
=	something#frag
mentrrz/javascript:alert('msg')/zquery=somethingr7zGhttp://www.python.org/javascript:alert('msg')/?query=something#fragmentsQhttp	://www.python
.org	/java
script:	alert('msg
')/?query
=	something#frag
mentrr*s/javascript:alert('msg')/squery=somethingfragmentsGhttp://www.python.org/javascript:alert('msg')/?query=something#fragmentzNhttp://www.python.org/java
script:	alert('msg
')/?query
=	something#frag
mentzht
tpr~r2)r.r/r?r:r2r3r4r6r7r;r<r=r>r9range)rArBrr2_s     rI!test_urlsplit_remove_unsafe_bytesz2UrlParseTestCase.test_urlsplit_remove_unsafe_bytesls;kLL!!#&6*#34!<="34Z0T*T*%56&%nomLL!!#&7+#45!=>"45[1T*T*%67&%opfq	tA%%c&%9AQXXv.QXXZ)rs	trc	ttdd}d}|jd|z}tjj|}|j
|jd|j
|jd|j
|jd|j
|jd|j
|jd	|j
|jd
|j
|jd|j
|jd|j
|jd
|j
|j!|||j#dz}tjj|}|j
|jd|j
|jd|j
|jd|j
|jd|j
|jd|j
|jd|j
|jd|j
|jd|j
|jd
|j
|j!|j#dd}tjj|jd|z}|j
|jd|j
|jd|j
|jd|j
|jd|j
|jd|j
|j!|tjjd}|j
tjj%|dd}|jddz|jdz}tdD]_}tjj||}|j
|jd|j
|j!day) Nr!r!utf-8rr"rr#rr$r%rr&rr+r(r,r)r-r.r*z)https://www.python.org:88/doc/?query=    rzwww.python.org:88z
query=    Xz
www.pypi.org z//www.python.org/r~r3zhttps://www.python.org/)bytesr4decoder.r/r?r:r2r3r4r6r7r;r<r=r>r9rvr@)rAnoisebase_urlrBrquery_spaces_urlr2r5s        rItest_urlsplit_strip_urlz(UrlParseTestCase.test_urlsplit_strip_urlseeAx()Lll7#h.LL!!#&6*#AB)+.V,V,V,%56$X.hoog..LL!!#&7+#BC*,/W-W-W-%67$X__W%=>GLL!!%,,w"7:J"JK7+#67),/$%56LL!!/2	
003_E"g&05<<3HHq	DA%%c&%9AQXXw/QXXZ)BC	Drc
TdD]
}tjjtjjfD]}dD]}|j	|||5d|z}d|zdz}|rM|jr3|jr#|j
d}|j
d}n
	dddt||}|j|j||jt5|jdddddd
y#1swYxYw#1swYxYw)	z Check handling of invalid ports.FT)	rz1.5z-10x10z-01_1z 1z1 u६)r;r/r>zwww.example.net:zhttp://rrrN)r.r/r?r0subTestisasciirvr:r3rrr>)rAr;r/r>r3rBrs       rItest_attributes_bad_portz)UrlParseTestCase.test_attributes_bad_ports"	#E ,,//1F1FG
#X
#DETJ#!3d!:'&036 %~~/DLLN)/w)?&)jj&9 (##"#J((6:!..z:#FF###
#
#	#####s+AD	49D	-
D:D	DD	D'
c	dD]}tjjtjjfD]}dD]}|j	|||5|dz}|r,|jr|j
d}n
	dddK||}|r|j|jdn|j|jddddy#1swYxYw)	z"Check handling of invalid schemes.rB)r+-0zhttp&u६http)r;r/r2z://www.example.netrrNrr)	r.r/r?r0rErFrvr:r2)rAr;r/r2rBrs      rItest_attributes_bad_schemez+UrlParseTestCase.test_attributes_bad_schemes"	;E ,,//1F1FG

;F;FEvN;$';; "{{}&)jj&9 (
;;"#J  ,,QXXs; ,,QXXr:;;;

;	;;;s+C	
AC	C%
cdd}tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|j|tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|j|d}tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|j|tjj|}|j|jd|j|j
d|j|jd|j|jd|j|jd|j|j|y)Nz0sip:alice@atlanta.com;maddr=239.255.255.1;ttl=15rs0sip:alice@atlanta.com;maddr=239.255.255.1;ttl=15r)r.r/r?r:r3r;r<r=r>r9r0)rAurirs   rItest_attributes_without_netlocz/UrlParseTestCase.test_attributes_without_netlocsJALL!!#&2&T*T*T*&S)LL!!#&2&T*T*T*&S)BLL!!#&3'T*T*T*&S)LL!!#&3'T*T*T*&S)rc|jtjjdd|jtjjddy)Nz http://example.com?blahblah=/foo)rzexample.comrrz
blahblah=/foors http://example.com?blahblah=/foo)rsexample.comrrs
blahblah=/foorrrs rItest_noslashzUrlParseTestCase.test_noslashsJ../QRM	O../RSS	Urc8|jtjjdd|jtjjdd|jtjjdd|jtjjdd|jtjjd	d
|jtjjddy)
Nr4)rrr4rrrz//www.python.org:80)rwww.python.org:80rrrrhttp://www.python.org:80rrSrrrrpath)rrrVrrrs//www.python.org:80)rwww.python.org:80rrrrhttp://www.python.org:80rrWrrrrrrs rItest_withoutschemez#UrlParseTestCase.test_withoutscheme!s
	
..v6'	)../DE4	6../IJ8	:	
..w7-	/../EF:	<../JK>	@rcl|jtjjdd|jtjjdd|jtjjdd|jtjjdd|jtjjd	d
|jtjjdd|jtjjd
d|jtjjdd|jtjjdd|jtjjdd|jtjjdd|jtjjddy)Nzhttp:80)rr80rrrzhttps:80)rrr\rrrzpath:80)r4rr\rrrr)rrrrrrzhttps:)rrrrrrrTrUshttp:80)rr80rrrshttps:80)rrr]rrrspath:80)rVrr]rrrshttp:)rrrrrrshttps:)rrrrrrrXrYrrs rItest_portseparatorz#UrlParseTestCase.test_portseparator4s..y9;TU..z:<VW..y9;TU..w78OP..x89QR../IJ8	:	
..z:<[\..{;=]^..z:<[\..x89VW..y9:XY../JK>	@rcb|jttjjdy)Nr)r	TypeErrorr.r/	urlencoders rI
test_usingsyszUrlParseTestCase.test_usingsysFs)V\\%;%;UCrc|jtjjdd|jtjjdd|jtjjdd|jtjjdd|jtjjd	d
|jtjjdd|jtjjd
d|jtjjddy)Nzs3://foo.com/stuff)s3foo.com/stuffrrrr)x-newschemererfrrrz*x-newscheme://foo.com/stuff?query#fragment)rgrerfrr6r7z!x-newscheme://foo.com/stuff?query)rgrerfrr6rss3://foo.com/stuff)ss3foo.com/stuffrrrsx-newscheme://foo.com/stuff)x-newschemerhrirrrs*x-newscheme://foo.com/stuff?query#fragment)rjrhrirqueryr2s!x-newscheme://foo.com/stuff?query)rjrhrirrkrrrs rItest_anyschemezUrlParseTestCase.test_anyschemeJs$../CD@	B../LMI	K../[\V	X../RSN	P	
../DEF	H../MNO	Q../\]\	^../STT	VrctjjtjjfD]:}|j	|5|dd}|j|jd|dd}|j|jd|j|ddjd|j|dd	jd|j|d
d	jd|j|djd|j|d
jd|j|d
djdddd=y#1swYIxYw)
N)functionzhttp://example.net/ftprshttp://example.net/sftprr4r3rVrr)r.r/r0r?rEr:r2)rAfuncrEs   rItest_default_schemez$UrlParseTestCase.test_default_scheme_sC\\**FLL,A,AB	@Dt,

@3U;  74f=  8  fe!4!;!;UC  fU!;!B!BEJ  gf!=!D!DfM  f!4!4b9  g!5!5s;  gr!2!9!93?

@

@	@

@

@s
DE44E>	c
Jd}|D]\}}}tjjtjjfD]O}|dk(r|tjjurd}|j	||5||d}|j|jd|jt||jd|z|j||ddjd||d	}|j|j||jt||j||j||dd	j||j||j|dddRy#1swYaxYw)
N)
)z
http:#fragr4r)z//example.net#fragr4r)zindex.html#fragr4r)z	;a=b#fragr5r)z	?a=b#fragr6r)z#fragr4r)z	abc#@fragr4@frag)z//abc#@fragr4rs)z//abc:80#@fragr4rs)z//abc#@frag:80r4z@frag:80r5r4)rBrnF)allow_fragmentsr#T)r.r/r0r?rEr:r7
assertTruegetattrendswithassertFalse)rAtestsrBattr
expected_fragrprEs       rItest_parse_fragmentsz%UrlParseTestCase.test_parse_fragmentsns
).	H$C}..0E0EF
H8#0E0E(E!D\\cD\9
H!#u=F$$V__b9OO#FD1::3;NOQ$$T#r5%9%B%BBG!#t<F$$V__mD$$#FD1::=IK$$T#r4%8%A%A%24$$T#Y%7%7G
H
H
H	H
H
Hs
;DFF"c|jtd5tjj	ddddd|jtd5tjj	ddddd|jtd5tjjddddd|jtd5tjjddddd|jtd5tjj
dddd|jtd5tjj
dddd|jtd5tjjdddd|jtd5tjjd	ddd|jtd5tjjd
dddd|jtd5tjjdd
dddy#1swY>xYw#1swYxYw#1swYxYw#1swYxYw#1swYwxYw#1swYFxYw#1swYxYw#1swYxYw#1swYxYw#1swYyxYw)NzCannot mix strrrr*r)rrrrrr)rr*rrrr)rrrrr)rr*rrrrshttp://python.org)	r/r`r.r/r0r?r8r@rrs rItest_mixed_types_rejectedz*UrlParseTestCase.test_mixed_types_rejectedsj
#
#I/?
@	=LL!!"2G<	=

#
#I/?
@	=LL!!"3V<	=

#
#I/?
@	=LL!!"2G<	=

#
#I/?
@	=LL!!"3V<	=

#
#I/?
@	NLL##$LM	N

#
#I/?
@	MLL##$KL	M

#
#I/?
@	JLL##$HI	J

#
#I/?
@	JLL##$HI	J

#
#I/?
@	LLL  !46JK	L

#
#I/?
@	LLL  !57JK	L	L%	=	=	=	=	=	=	=	=	N	N	M	M	J	J	J	J	L	L	L	Lsw!I4!J!J!J J( J5 K
 K!K
!K'4I>JJJ%(J25J?KKK$'K0ct|j}|j}|j|j|d|z}d|z}||}||}d}d}	|j|||j|j
||j|j
||j|j
|||j|j
|||j|j
||	||j|j
||	||j|||j|j||j|j||j|j|||j|j|||j|j||	||j|j||	|y)N)r)rrrstrict)rR_fields_encoded_counterpartassertIs_decoded_counterpartr:r<rv)
rAstr_typenum_args
bytes_typestr_args
bytes_args
str_resultbytes_resultencodingerrorss
          rI_check_result_typez#UrlParseTestCase._check_result_typesx''(22


j55x@8#h&
x(
!:.X.,,.9,,.
;,,X6A,,X6
C,,Xv>I,,Xv>
Kz2**,j9**,l;**84jA**84lC**8V<jI**8V<lKrctjjtjjtjjg}|D]}|j|yr-)r.r/DefragResultSplitResultParseResultr)rAresult_typesresult_types   rItest_result_pairsz"UrlParseTestCase.test_result_pairssQ,,
#
#
,,
"
"
,,
"
"

(	1K##K0	1rc"tjjdd}|j|ddgitjjdd}|j|ddgitjjdd}|j|dd	gitjjd
d}|j|ddgitjjd
dd
}|j|ddgiy)N	key=Ł%E9latin-1rkeyŁékey=Ł%C3%A9r9rrŁ��
key=Ł%E9-Ł�-ignorerrŁ-)r.r/r[r:rArEs  rItest_parse_qs_encodingz'UrlParseTestCase.test_parse_qs_encodings&&&K%,!89&&'9G&L%,!89&&'9G&L%*>)?!@A&&'7'&J%/):!;<&&'7'AI'K%)!56rctjjdd}|j|dgtjjdd}|j|dgtjjdd}|j|dgtjjd	d}|j|d
gtjjd	dd}|j|d
gy)Nrrr)rrrr9rr)rrr)rrrr)rr)r.r/rQr:rs  rItest_parse_qsl_encodingz(UrlParseTestCase.test_parse_qsl_encodings'')'L"7!89''(:W'M"7!89''(:W'M"?!@A''(87'K":!;<''(87AI(K"4!56rc(|jt5tjj	djdgdzddddtjj	djdgdzdy#1swY>xYw)Nrza=a
)max_num_fields)rrr.r/r[joinrs rItest_parse_qsl_max_num_fieldsz.UrlParseTestCase.test_parse_qsl_max_num_fieldssu


z
*	KLL!!#((E72:"6r!J	Kchhwrz22F	K	Ks5BBc
difdifdddgifddgdgd	fd
dddgifd
ifdifdddgifddgdgdfddddgifg
}|D]\}}|jd|d|5tjj|d}|j	||d|ztjj|d
}|j	||d|zdddy#1swYxYw)N;;;r"r	rr$r
rr
a=1;a=2rr;;;r&rrr(rrra=1;a=2rr!
Original: , Expected: 	separatorrN)rEr.r/r[r:)rAparse_qs_semicolon_casesrTrUrEresult_bytess      rItest_parse_qs_separatorz(UrlParseTestCase.test_parse_qs_separators7
"I
2J
cC5\"
5'89
sCj)*
2J
BK
tdVn%
VHVH=>
$t-.$
 5	RLD&
4(,vjIJ
R..ts.C  1Cd1JK%||44TT4J  v7ID7PQ	
R
R	R
R
Rs
A/CC	cdgfdgfddgfdddgfdd	d
gfdgfdgfd
dgfdddgfdddgfg
}|D]\}}|jd|d|5tjj|d}|j	||d|ztjj|d}|j	||d|zdddy#1swYxYw)Nrrr"r
r$rrrrrrrr&rr(rrrrr rrrrN)rEr.r/rQr:)rAparse_qsl_semicolon_casesrTrUrErs      rItest_parse_qsl_separatorz)UrlParseTestCase.test_parse_qsl_separators
"I
2J
j\"
\<89
Z01
2J
BK
|n%
nn=>
,56%
!6	RLD&
4(,vjIJ
R///D  1Cd1JK%||55dd5K  v7ID7PQ	
R
R	R
R
Rs

A/CC
	ctjjddgddd}t|j	dhdk(sJGdd	}tjjd
|id}|j|dy)NrOr~)r r
Tr>a=1a=2b=3b=4b=5ceZdZdZy):UrlParseTestCase.test_urlencode_sequences.<locals>.Trivialcy)Ntrivialrs rI__str__zBUrlParseTestCase.test_urlencode_sequences.<locals>.Trivial.__str__s rN)__name__
__module____qualname__rrrrITrivialrs
!rrr	z	a=trivial)r.r/rasetrDr:)rArErs   rItest_urlencode_sequencesz)UrlParseTestCase.test_urlencode_sequencessv''q!f9(EtL6<<$%)LLL	!	!''gi(8$?-rctjjddi}|j|dtjjdditjj}|j|dtjjddidtjj}|j|d	y)
Nr	z
some valueza=some+valuezsome value/another)	quote_viaza=some%20value%2Fanotherr)saferza=some%20value/another)r.r/rar:quoters  rItest_urlencode_quote_viaz)UrlParseTestCase.test_urlencode_quote_via!s''l(;<0''.B(C28,,2D2D(F!;<''.B(C-0FLL<N<N(P!9:rc|jttjjdtjj	d}|j|dtjj	d}|j|dtjj	ddz}|j|ddztjj	d	d
z}|j|dd
zy)Nrsarchaeological arcanazarchaeological%20arcanarrAi'Asz/ izz%01/%20)rr`r.r/quote_from_bytesr:rs  rItest_quote_from_bytesz&UrlParseTestCase.test_quote_from_bytes+s)V\\%B%BEJ../GH!:;..s3$..tF{;V,..z'/ABG!34rctjjd}|j|dtjjd}|j|dy)Nz	abc%20defsabc defrr)r.r/unquote_to_bytesr:rs  rItest_unquote_to_bytesz&UrlParseTestCase.test_unquote_to_bytes6sJ..{;,..r2%rc|jttjjdd|jttjjddy)Nsfoor9rr)r)rr`r.r/rrs rItest_quote_errorsz"UrlParseTestCase.test_quote_errors<sI)V\\%7%7#*		,)V\\%7%7Qrctjjd}|j|jd|j|j
dtjjd}|j|jd|j|j
dtjj
d}|j|jd|j|j
dtjj
d}|j|jd|j|j
dy)Nztel:+31-641044153telz
+31-641044153ztel:+31641044153z+31641044153)r.r/r?r:r2r4r0)rAp1p2s   rItest_issue14072z UrlParseTestCase.test_issue14072As
\\
"
"#6
7E*/2
\\
"
"#5
6E*.1
\\
"
"#6
7E*/2
\\
"
"#5
6E*.1rc|jttjjd|jttjjd|jttjjd|jttjjd|jttjjd|jttjjd|jttjjd|jttjjd|jttjjd	|jttjjd
y)Nz&Scheme://user@[192.0.2.146]/Path?Queryz-Scheme://user@[important.com:8000]/Path?Queryz#Scheme://user@[v123r.IP]/Path?Queryz Scheme://user@[v12ae]/Path?QueryzScheme://user@[v.IP]/Path?Queryz Scheme://user@[v123.]/Path?QueryzScheme://user@[v]/Path?Queryz5Scheme://user@[0439:23af::2309::fae7:1234]/Path?QueryzJScheme://user@[0439:23af:2309::fae7:1234:2342:438e:192.0.2.146]/Path?QueryzScheme://user@]v6a.ip[/Path)rrr.r/r?rs rItest_invalid_bracketed_hostsz-UrlParseTestCase.test_invalid_bracketed_hostsPs**fll&;&;=ef*fll&;&;=lm*fll&;&;=bc*fll&;&;=_`*fll&;&;=^_*fll&;&;=_`*fll&;&;=[\*fll&;&;=tu*fll&;&;>J	K*fll&;&;=Z[rctjjd}|j|jd|j|j
d|j|jdtjjd}|j|jd|j|j
d|j|jdtjjd}|j|jd|j|j
d|j|jdy)	Nz!scheme://user@[v6a.ip]/path?queryzv6a.ipuser/pathz4scheme://user@[0439:23af:2309::fae7%test]/path?queryz0439:23af:2309::fae7%testzEscheme://user@[0439:23af:2309::fae7:1234:192.0.2.146%test]/path?queryz*0439:23af:2309::fae7:1234:192.0.2.146%test)r.r/r?r:r=r;r4)rArrp3s    rItest_splitting_bracketed_hostsz/UrlParseTestCase.test_splitting_bracketed_hosts\s
\\
"
"#F
Gh/f-'*
\\
"
"#Y
Z&ABf-'*
\\
"
"#j
k&RSf-'*rc`d}tjjd}|jt|5|j
dddtjj
d}|jt|5|j
dddy#1swYTxYw#1swYyxYw)Nz3Port could not be cast to integer value as 'oracle'z%http://Server=sde; Service=sde:oracle)r.r/r0r/rr>r?)rAmessagerrs    rI!test_port_casting_failure_messagez2UrlParseTestCase.test_port_casting_failure_messagejsG
\\
"
"#J
K

#
#J
8	GG	\\
"
"#J
K

#
#J
8	GG							s
B
B$B!$B-ctjjd}|j|jd|j|j
d|j|jdtjjd}|j|jd|j|j
d|j|jdtjjd}|j|jd|j|j
d	|j|jd
tjjd}|j|jd|j|j
d|j|jd
y)Nz"tel:123-4;phone-context=+1-650-516rz123-4zphone-context=+1-650-516ztel:+1-201-555-0123z+1-201-555-0123rz"tel:7042;phone-context=example.com7042zphone-context=example.comz%tel:863-1234;phone-context=+1-914-555z863-1234zphone-context=+1-914-555)r.r/r0r:r2r4r5)rArs  rItest_telurl_paramsz#UrlParseTestCase.test_telurl_paramstsJ
\\
"
"#G
HE*'*$>?
\\
"
"#8
9E*"34B'
\\
"
"#G
HE*&)$?@
\\
"
"#J
KE**-$>?rctjjtjj}|j	dt|y)NQuoter)r.r/_Quoter_ALWAYS_SAFEassertInrepr)rAquoters  rItest_Quoter_reprz!UrlParseTestCase.test_Quoter_reprs2%%fll&?&?@

hV-rc@tjjyr-)r.r/clear_cachers rI"test_clear_cache_for_code_coveragez3UrlParseTestCase.test_clear_cache_for_code_coverages  "rc|jt5tjj}dddy#1swYyxYw)z5Test that urllib.parse.__getattr__() fails correctly.N)rAttributeErrorr.r/this_does_not_exist)rAunuseds  rI!test_urllib_parse_getattr_failurez2UrlParseTestCase.test_urllib_parse_getattr_failures4


~
.	6\\55F	6	6	6s	:AcDg}hd}ttjD]T}|jds||vrt	tj|}t	|dddk(sD|j|V|j
tjj|y)N>unwrapsplittagto_bytes	splitattr	splithost	splitport	splittype	splituser
ResultBase
splitnport
splitquery
splitvaluersplitpasswdr5rzurllib.parse)dirr.r/
startswithrwappendassertCountEqual__all__)rArundocumentednameobjects     rItest_allzUrlParseTestCase.test_alls
%	&Ds#t|';V\\40Fv|T2nD%	&	
fll22H=rcd}|Dchc]}djt|}}ttt	dt
jDcgc]L}tj|r5|ttj|jzr||vr|N}}|jd||jd|tjjd|jt 5tjjdddddD]}d	D]}|D]}d
j||j|}|j#|djt|5|jt 5tjj|ddddddycc}wcc}w#1swYxYw#1swY.xYw#1swYxYw)Nz/:#?@z{:04X}u℀u#uhttp://プ:80uhttp://プ︓80)rrro)znetloc{}false.netloczn{}user@netlocz{}://{}/path)rBchar)formatordmapchrr4sys
maxunicodeunicodedata
decompositionrrDrr.r/r?rrrE)rA
illegal_charsc	hex_charsdenorm_charsr2r3rBs        rItest_urlsplit_normalizationz,UrlParseTestCase.test_urlsplit_normalizations 
6CDX__SV,D	D3c3>> :;
((+S!:!:1!=!C!C!EFF&


	


h-

h-	67


z
*	ALL!!"?@	A/	7FD
7%7A(//

a8HIC#HOOCF4KL7!..z:7"LL11#67777
7	7#E
	A	A7777s<!GAG? GG1	 G%8G1	G"%G.*G1	1G:
N)6rrrrJrXr\rrrrrrrrrrrrr0r6r@rGrLrOrQrZr^rbrlrqr}rrrrrrrrrrrrrrrrrrrrrrr*rrrIr+r+Gs(18f77&5P$=LJS"A`@
%JZ7Br5&n0Nd4.M[z#tJ9Dv#&;$'*RU@&@$DV*
@HBL0L2177G
R*R*.;	5&R

2
\+@*.#6
> 7rr+cXeZdZdZdZdZdZdZdZdZ	dZ
d	Zd
ZdZ
dZd
Zy)
Utility_Testsz=Testcase to test the various utility functions in the urllib.c(tjj}|j|dd|j|dd|j|dd|j|dd|j|d	d
y)Nztype:opaquestring)ropaquestringr.)Nr.
:opaquestring)Nr/ztype:)rrztype:opaque:string)rz
opaque:string)r.r/
_splittyper:)rArs  rItest_splittypezUtility_Tests.test_splittypesLL++	#679QR>24JK?35LM7+\:#78:STrctjj}|j|dd|j|dd|j|dd|j|dd|j|d	d
|j|dd|j|d
d|j|dd|j|dd|j|ddy)Nz%//www.example.org:80/foo/bar/baz.html)www.example.org:80/foo/bar/baz.htmlz//www.example.org:80)r3rr4)Nr4z//127.0.0.1#@host.com)	127.0.0.1/#@host.comz//127.0.0.1#@host.com:80)r5z/#@host.com:80z//127.0.0.1:80#@host.com)z127.0.0.1:80r6z///file)rz/filez//example.net/file;)example.netz/file;z//example.net/file?)r7z/file?z//example.net/file#)r7z/file#)r.r/
_splithostr:)rAr	s  rItest_splithostzUtility_Tests.test_splithostsLL++	#JKD	F#9:3	5#674	6	
#:;5	7#=>8	:#=>8	:	
9-&	(	
#892	4#892	4#892	4rc(tjj}|j|dd|j|dd|j|dd|j|dd|j|d	d
y)Nr")	User:Passwww.python.org:080z@www.python.org:080)rr<r<)Nr<z
User:Pass@)r;rr')zUser@example.com:Passr<)r.r/
_splituserr:)rArs  rItest_splituserzUtility_Tests.test_splitusersLL++	#AB<	>#893	5#785	7<0*	,#MNH	Jrctjj}|j|dd|j|dd|j|dd|j|dd|j|d	d
|j|dd|j|d
d|j|dd|j|dd|j|dd|j|dd|j|dd|j|ddy)Nzuser:ab)rabzuser:a
b)rza
bzuser:a	b)rza	bzuser:a
b)rza
bzuser:ab)rzabzuser:ab)rzabzuser:a:b)rza:bzuser:a b)rr
z	user 2:ab)zuser 2r@z
user+1:a+b)zuser+1za+bzuser:)rrr)rNz:ab)rr@)r.r/_splitpasswdr:)rArs  rItest_splitpasswdzUtility_Tests.test_splitpasswds+ll//Y/@[13CD[13CD[13CD[13CD[13CDZ0/BZ0/B[13CD\24EFW-|<V,n=U+Z8rctjj}|j|dd|j|dd|j|dd|j|dd|j|dd	|j|d
d|j|dd
|j|ddy)N	parrot:88)parrot88rErENparrot:r5)r5N
parrot:cheese)rINz[::1]:88)[::1]rFrJ)rJNz:88)rrF)r.r/
_splitportr:)rAr
s  rItest_splitportzUtility_Tests.test_splitportsLL++	;/1AB8,.>?9-/?@;/1DE?35LM:.@7+_=5):6rc tjj}|j|dd|j|dd|j|ddd|j|dd|j|ddd|j|dd	|j|ddd
|j|dd|j|ddd|j|d
dy)NrD)rEr:rE)rE7)rErOrHr5)r5rN)r5rOrIrGz
parrot: +1_0 )r.r/_splitnportr:)rArs  rItest_splitnportzUtility_Tests.test_splitnports\\--
K0.AH-~>Hb1>BI.?Ir2NCK02CDK46GHO46FGOR8:JKO46FGrctjj}|j|dd|j|dd|j|dd|j|ddy)	Nhttp://python.org/fake?foo=bar)http://python.org/fakefoo=barzhttp://python.org/fake?foo=bar?)rSrrT)rTNz?foo=bar)rrU)r.r/_splitqueryr:)rArs  rItest_splitqueryzUtility_Tests.test_splitquery#su\\--
$DE>	@$EF?	A$<=9	;J/Arc(tjj}|j|dd|j|dd|j|dd|j|dd|j|d	d
y)Nhttp://example.com?foo=bar#baz)http://example.com?foo=barbazzhttp://example.com?foo=bar#)rZrz#baz)rr[rZ)rZNz"http://example.com?foo=bar#baz#boo)rYboo)r.r/	_splittagr:)rArs  rI
test_splittagzUtility_Tests.test_splittag/s<<))"BC>	@"?@;	=&);7">?=	?"FGB	Drctjj}|j|ddddgf|j|dddgf|j|ddddgf|j|ddgfy)Nz/path;attr1=value1;attr2=value2rzattr1=value1zattr2=value2z/path;rz;attr1=value1;attr2=value2)r.r/
_splitattrr:)rArs  rItest_splitattrzUtility_Tests.test_splitattr;sLL++	#DE!NN#CD	F8,wo>#?@~~>?	A7+gr];rc(tjj}|j|dd|j|dd|j|dd|j|dd|j|d	d
y)NrU)rbarzfoo=)rrz=bar)rrcfoobar)rdNzfoo=bar=baz)rzbar=baz)r.r/_splitvaluer:)rArs  rItest_splitvaluezUtility_Tests.test_splitvalueDs~\\--
I.?F+[9F+[9H-/?@M24FGrctjjd}|j|d|j	t
tjjdy)Nzhttp://www.python.orguhttp://www.python.org/mediæval)r.r/	_to_bytesr:rUnicodeErrorrs  rI
test_to_byteszUtility_Tests.test_to_bytesNsH''(?@!89,(>(>?	ArctdD]3}tjj|}|j|d5y)N)z<URL:scheme://host/path>z<scheme://host/path>zURL:scheme://host/pathscheme://host/pathrl)r.r/rr:)rAwrapped_urlrBs   rItest_unwrapzUtility_Tests.test_unwrapTs9L	8K,,%%k2CS"67	8rN)rrr__doc__r1r9r>rBrLrQrWr^rarfrjrnrrrIr,r,sHGU4:J9$	7H
B
D<HA8rr,cTeZdZdZdZdZdZdZdZdZ	dZ
d	Zd
ZdZ
dZy
)DeprecationTestc*|jt5}tjj}|j|tjjddd|jdtjy#1swY/xYw)NzQuoter will be removed)
assertWarnsDeprecationWarningr.r/rrrrstrwarning)rAcm	old_classs   rItest_Quoter_deprecationz'DeprecationTest.test_Quoter_deprecation]sh


0
1	;R++IMM)V\\%9%9:	;	


.BJJ@	;	;sAB		Bc|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzUurllib.parse.splittype() is deprecated as of 3.8, use urllib.parse.urlparse() instead)rsrtr.r/rr:rurvrArws  rItest_splittype_deprecationz*DeprecationTest.test_splittype_deprecationcX


0
1	'RLL""2&	'RZZ?	@	'	' A$$A-c|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzUurllib.parse.splithost() is deprecated as of 3.8, use urllib.parse.urlparse() instead)rsrtr.r/r	r:rurvr{s  rItest_splithost_deprecationz*DeprecationTest.test_splithost_deprecationjr}r~c|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzUurllib.parse.splituser() is deprecated as of 3.8, use urllib.parse.urlparse() instead)rsrtr.r/rr:rurvr{s  rItest_splituser_deprecationz*DeprecationTest.test_splituser_deprecationqr}r~c|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzWurllib.parse.splitpasswd() is deprecated as of 3.8, use urllib.parse.urlparse() instead)rsrtr.r/rr:rurvr{s  rItest_splitpasswd_deprecationz,DeprecationTest.test_splitpasswd_deprecationxsX


0
1	)RLL$$R(	)RZZ?	@	)	)r~c|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzUurllib.parse.splitport() is deprecated as of 3.8, use urllib.parse.urlparse() instead)rsrtr.r/r
r:rurvr{s  rItest_splitport_deprecationz*DeprecationTest.test_splitport_deprecationr}r~c|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzVurllib.parse.splitnport() is deprecated as of 3.8, use urllib.parse.urlparse() instead)rsrtr.r/rr:rurvr{s  rItest_splitnport_deprecationz+DeprecationTest.test_splitnport_deprecationX


0
1	(RLL##B'	(RZZ?	@	(	(r~c|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzVurllib.parse.splitquery() is deprecated as of 3.8, use urllib.parse.urlparse() instead)rsrtr.r/rr:rurvr{s  rItest_splitquery_deprecationz+DeprecationTest.test_splitquery_deprecationrr~c|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzTurllib.parse.splittag() is deprecated as of 3.8, use urllib.parse.urlparse() instead)rsrtr.r/rr:rurvr{s  rItest_splittag_deprecationz)DeprecationTest.test_splittag_deprecationsX


0
1	&RLL!!"%	&RZZ?	@	&	&r~c|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzUurllib.parse.splitattr() is deprecated as of 3.8, use urllib.parse.urlparse() instead)rsrtr.r/rr:rurvr{s  rItest_splitattr_deprecationz*DeprecationTest.test_splitattr_deprecationr}r~c|jt5}tjj	dddd|jt
jdy#1swY/xYw)NrzWurllib.parse.splitvalue() is deprecated as of 3.8, use urllib.parse.parse_qsl() instead)rsrtr.r/rr:rurvr{s  rItest_splitvalue_deprecationz+DeprecationTest.test_splitvalue_deprecationsY


0
1	(RLL##B'	(RZZ@	A	(	(r~c|jt5}tjj	dddd|jt
jdy#1swY/xYw)Nrz/urllib.parse.to_bytes() is deprecated as of 3.8)rsrtr.r/rr:rurvr{s  rItest_to_bytes_deprecationz)DeprecationTest.test_to_bytes_deprecationsV


0
1	&RLL!!"%	&RZZJ	L	&	&r~N)rrrryr|rrrrrrrrrrrrrIrqrq[sJA@@@@@@@@@ALrrq__main__)r"r$unittesturllib.parser.rrrrrPrZTestCaser+r,rqrmainrrrI<module>rs
%##H"I	2J8*	I;9+	I;j\\<01Z()"I	2J
BK	J<
[M	K=
[M|nnn56,-.k]'()}o*+,1>H"I	2J2t*	B;3+	C";cC5\5'01sCj!""I	2J
BK	C#<
S4&M	D3%=
TC5MtdVnVHVH56$t%&dSE]S;-()utfod\?+,16z7x((z7x#U8H%%U8pRLh''RLjzHMMOr