@@ -177,32 +177,44 @@ var parseTests = {
177
177
'path' : '/Y'
178
178
} ,
179
179
180
+ // + not an invalid host character
181
+ // per https://url.spec.whatwg.org/#host-parsing
182
+ 'http://x.y.com+a/b/c' : {
183
+ 'href' : 'http://x.y.com+a/b/c' ,
184
+ 'protocol' : 'http:' ,
185
+ 'slashes' : true ,
186
+ 'host' : 'x.y.com+a' ,
187
+ 'hostname' : 'x.y.com+a' ,
188
+ 'pathname' : '/b/c' ,
189
+ 'path' : '/b/c'
190
+ } ,
191
+
180
192
// an unexpected invalid char in the hostname.
181
- 'HtTp://x.y.cOm* a/b/c?d=e#f g<h>i' : {
182
- 'href' : 'http://x.y.com/* a/b/c?d=e#f%20g%3Ch%3Ei' ,
193
+ 'HtTp://x.y.cOm; a/b/c?d=e#f g<h>i' : {
194
+ 'href' : 'http://x.y.com/; a/b/c?d=e#f%20g%3Ch%3Ei' ,
183
195
'protocol' : 'http:' ,
184
196
'slashes' : true ,
185
197
'host' : 'x.y.com' ,
186
198
'hostname' : 'x.y.com' ,
187
- 'pathname' : '/* a/b/c' ,
199
+ 'pathname' : '; a/b/c' ,
188
200
'search' : '?d=e' ,
189
201
'query' : 'd=e' ,
190
202
'hash' : '#f%20g%3Ch%3Ei' ,
191
- 'path' : '/* a/b/c?d=e'
203
+ 'path' : '; a/b/c?d=e'
192
204
} ,
193
205
194
206
// make sure that we don't accidentally lcast the path parts.
195
- 'HtTp://x.y.cOm* A/b/c?d=e#f g<h>i' : {
196
- 'href' : 'http://x.y.com/* A/b/c?d=e#f%20g%3Ch%3Ei' ,
207
+ 'HtTp://x.y.cOm; A/b/c?d=e#f g<h>i' : {
208
+ 'href' : 'http://x.y.com/; A/b/c?d=e#f%20g%3Ch%3Ei' ,
197
209
'protocol' : 'http:' ,
198
210
'slashes' : true ,
199
211
'host' : 'x.y.com' ,
200
212
'hostname' : 'x.y.com' ,
201
- 'pathname' : '/* A/b/c' ,
213
+ 'pathname' : '; A/b/c' ,
202
214
'search' : '?d=e' ,
203
215
'query' : 'd=e' ,
204
216
'hash' : '#f%20g%3Ch%3Ei' ,
205
- 'path' : '/* A/b/c?d=e'
217
+ 'path' : '; A/b/c?d=e'
206
218
} ,
207
219
208
220
'http://x...y...#p' : {
@@ -517,17 +529,17 @@ var parseTests = {
517
529
'path' : '/'
518
530
} ,
519
531
520
- 'http://www.Äffchen.cOm* A/b/c?d=e#f g<h>i' : {
521
- 'href' : 'http://www.xn--ffchen-9ta.com/* A/b/c?d=e#f%20g%3Ch%3Ei' ,
532
+ 'http://www.Äffchen.cOm; A/b/c?d=e#f g<h>i' : {
533
+ 'href' : 'http://www.xn--ffchen-9ta.com/; A/b/c?d=e#f%20g%3Ch%3Ei' ,
522
534
'protocol' : 'http:' ,
523
535
'slashes' : true ,
524
536
'host' : 'www.xn--ffchen-9ta.com' ,
525
537
'hostname' : 'www.xn--ffchen-9ta.com' ,
526
- 'pathname' : '/* A/b/c' ,
538
+ 'pathname' : '; A/b/c' ,
527
539
'search' : '?d=e' ,
528
540
'query' : 'd=e' ,
529
541
'hash' : '#f%20g%3Ch%3Ei' ,
530
- 'path' : '/* A/b/c?d=e'
542
+ 'path' : '; A/b/c?d=e'
531
543
} ,
532
544
533
545
'http://SÉLIER.COM/' : {
0 commit comments