Bug 601299: Find RegExpStatics in cx->globalObject if necessary. (r=mrbkap)
[mozilla-central.git] / netwerk / test / urlparse.dat
blob3b607d4e6043e3f3bf5f51ef3a87b917aa59152c
1 # Any blank lines and those beginning with # are comments and
2 # ignored. To add additional test cases that could potentially
3 # break URL parsing in mozilla add the input URL on a new line
4 # and follow it with the expected output for the standard URL
5 # parser and one line for the case when the URL is really
6 # created. Then run urltest with the -std option and without it
7 # on this file and hopefully the expected output should match
8 # the one from the program.
9 # - Gagan Saksena 03/28/00
12 http://username:password@hostname.com:80/pathname/./more/stuff/../path
13 http,username,password,hostname.com,80,/pathname/more/,path,,,,,http://username:password@hostname.com:80/pathname/more/path
14 http,username,password,hostname.com,80,/pathname/more/,path,,,,,http://username:password@hostname.com/pathname/more/path
16 username@host:8080/path
17 ,username,,host,8080,/,path,,,,,username@host:8080/path
18 Can not create URL
20 http://gagan/
21 http,,,gagan,-1,/,,,,,,http://gagan/
22 http,,,gagan,-1,/,,,,,,http://gagan/
24 scheme:host/netlib
25 scheme,,,host,-1,/,netlib,,,,,scheme://host/netlib
26 Can not create URL
28 mailbox:///foo
29 mailbox,,,,-1,/,foo,,,,,mailbox:///foo
30 mailbox,,,,-1,/,foo,,,,,mailbox:///foo
32 scheme:user@hostname.edu:80/pathname
33 scheme,user,,hostname.edu,80,/,pathname,,,,,scheme://user@hostname.edu:80/pathname
34 Can not create URL
36 http://username:password@hostname:80/pathname
37 http,username,password,hostname,80,/,pathname,,,,,http://username:password@hostname:80/pathname
38 http,username,password,hostname,80,/,pathname,,,,,http://username:password@hostname/pathname
40 http://username:password@hostname:8080/path/filebasename.fileextension;param?query#ref
41 http,username,password,hostname,8080,/path/,filebasename,fileextension,param,query,ref,http://username:password@hostname:8080/path/filebasename.fileextension;param?query#ref
42 http,username,password,hostname,8080,/path/,filebasename,fileextension,param,query,ref,http://username:password@hostname:8080/path/filebasename.fileextension;param?query#ref
44 resource:/pathname
45 resource,,,,-1,/,pathname,,,,,resource:///pathname
46 resource,,,,-1,/,pathname,,,,,resource:///pathname
48 ftp://uname%here.com:pwd@there.com/aPath/a.html
49 ftp,uname%here.com,pwd,there.com,-1,/aPath/,a,html,,,,ftp://uname%here.com:pwd@there.com/aPath/a.html
50 ftp,uname%here.com,pwd,there.com,-1,/aPath/,a,html,,,,ftp://uname%here.com:pwd@there.com/aPath/a.html
52 http://www.inf.bme.hu?foo=bar
53 http,,,www.inf.bme.hu,-1,/,,,,foo=bar,,http://www.inf.bme.hu/?foo=bar
54 http,,,www.inf.bme.hu,-1,/,,,,foo=bar,,http://www.inf.bme.hu/?foo=bar
56 http://test.com/aPath/a.html#/1/2
57 http,,,test.com,-1,/aPath/,a,html,,,/1/2,http://test.com/aPath/a.html#/1/2
58 http,,,test.com,-1,/aPath/,a,html,,,/1/2,http://test.com/aPath/a.html#/1/2
60 http://user:pass@ipaddres:2/get?foo/something
61 http,user,pass,ipaddres,2,/,get,,,foo/something,,http://user:pass@ipaddres:2/get?foo/something
62 http,user,pass,ipaddres,2,/,get,,,foo/something,,http://user:pass@ipaddres:2/get?foo/something
64 # testing different versions of http urls
65 http:www.mozilla.org
66 http,,,www.mozilla.org,-1,/,,,,,,http://www.mozilla.org/
67 http,,,www.mozilla.org,-1,/,,,,,,http://www.mozilla.org/
69 http:/www.mozilla.org
70 http,,,,-1,/,www.mozilla,org,,,,http:///www.mozilla.org
71 http,,,www.mozilla.org,-1,/,,,,,,http://www.mozilla.org/
73 # testing cap letters (23927)
74 HtTp://wWw.mozilLa.org
75 http,,,www.mozilla.org,-1,/,,,,,,http://www.mozilla.org/
76 http,,,www.mozilla.org,-1,/,,,,,,http://www.mozilla.org/
78 # testing spaces (15150)
79 go.com.au?mozilla bug reports
80 ,,,go.com.au,-1,/,,,,mozilla%20bug%20reports,,go.com.au/?mozilla%20bug%20reports
81 Can not create URL
83 http://go.com.au?mozilla bug reports
84 http,,,go.com.au,-1,/,,,,mozilla%20bug%20reports,,http://go.com.au/?mozilla%20bug%20reports
85 http,,,go.com.au,-1,/,,,,mozilla%20bug%20reports,,http://go.com.au/?mozilla%20bug%20reports
87 # testing for multiple params (14801)
88 http://ad.doubleclick.net/ad/cbsmw.button.com/SIDEBAR_BUTTONS;sz=88x31;kw=DBCC;tile=4;ord=1864641213378545414
89 http,,,ad.doubleclick.net,-1,/ad/cbsmw.button.com/,SIDEBAR_BUTTONS,,sz=88x31;kw=DBCC;tile=4;ord=1864641213378545414,,,http://ad.doubleclick.net/ad/cbsmw.button.com/SIDEBAR_BUTTONS;sz=88x31;kw=DBCC;tile=4;ord=1864641213378545414
90 http,,,ad.doubleclick.net,-1,/ad/cbsmw.button.com/,SIDEBAR_BUTTONS,,sz=88x31;kw=DBCC;tile=4;ord=1864641213378545414,,,http://ad.doubleclick.net/ad/cbsmw.button.com/SIDEBAR_BUTTONS;sz=88x31;kw=DBCC;tile=4;ord=1864641213378545414
92 fxqn:/us/va/reston/cnri/ietf/24/asdf%*.fred
93 fxqn,,,,-1,/us/va/reston/cnri/ietf/24/,asdf%*,fred,,,,fxqn:///us/va/reston/cnri/ietf/24/asdf%*.fred
94 Can not create URL
96 news:3B5C133C.2080505@foobar.net
97 news,3B5C133C.2080505,,foobar.net,-1,/,,,,,,news://3B5C133C.2080505@foobar.net/
98 news,3B5C133C.2080505,,foobar.net,-1,/,,,,,,news://3B5C133C.2080505@foobar.net/
100 http://host/path/%2E%2E/file%2Ehtml
101 http,,,host,-1,/,file%2Ehtml,,,,,http://host/file%2Ehtml
102 http,,,host,-1,/,file%2Ehtml,,,,,http://host/file%2Ehtml