|
1 | 1 | [
|
| 2 | + |
2 | 3 | "# Based on http://trac.webkit.org/browser/trunk/LayoutTests/fast/url/script-tests/segments.js",
|
3 |
| - "# AS OF https://github.com/jsdom/whatwg-url/commit/35f04dfd3048cf6362f4398745bb13375c5020c2", |
| 4 | + "# AS OF https://github.com/web-platform-tests/wpt/commit/551c9d604fb8b97d3f8c65793bb047d15baddbc2", |
4 | 5 | {
|
5 | 6 | "input": "http://example\t.\norg",
|
6 | 7 | "base": "http://example.org/foo/bar",
|
|
6446 | 6447 | "search": "",
|
6447 | 6448 | "hash": ""
|
6448 | 6449 | },
|
| 6450 | + "Serialize /. in path", |
| 6451 | + { |
| 6452 | + "input": "non-spec:/.//", |
| 6453 | + "base": "about:blank", |
| 6454 | + "href": "non-spec:/.//", |
| 6455 | + "protocol": "non-spec:", |
| 6456 | + "username": "", |
| 6457 | + "password": "", |
| 6458 | + "host": "", |
| 6459 | + "hostname": "", |
| 6460 | + "port": "", |
| 6461 | + "pathname": "//", |
| 6462 | + "search": "", |
| 6463 | + "hash": "" |
| 6464 | + }, |
| 6465 | + { |
| 6466 | + "input": "non-spec:/..//", |
| 6467 | + "base": "about:blank", |
| 6468 | + "href": "non-spec:/.//", |
| 6469 | + "protocol": "non-spec:", |
| 6470 | + "username": "", |
| 6471 | + "password": "", |
| 6472 | + "host": "", |
| 6473 | + "hostname": "", |
| 6474 | + "port": "", |
| 6475 | + "pathname": "//", |
| 6476 | + "search": "", |
| 6477 | + "hash": "" |
| 6478 | + }, |
| 6479 | + { |
| 6480 | + "input": "non-spec:/a/..//", |
| 6481 | + "base": "about:blank", |
| 6482 | + "href": "non-spec:/.//", |
| 6483 | + "protocol": "non-spec:", |
| 6484 | + "username": "", |
| 6485 | + "password": "", |
| 6486 | + "host": "", |
| 6487 | + "hostname": "", |
| 6488 | + "port": "", |
| 6489 | + "pathname": "//", |
| 6490 | + "search": "", |
| 6491 | + "hash": "" |
| 6492 | + }, |
| 6493 | + { |
| 6494 | + "input": "non-spec:/.//path", |
| 6495 | + "base": "about:blank", |
| 6496 | + "href": "non-spec:/.//path", |
| 6497 | + "protocol": "non-spec:", |
| 6498 | + "username": "", |
| 6499 | + "password": "", |
| 6500 | + "host": "", |
| 6501 | + "hostname": "", |
| 6502 | + "port": "", |
| 6503 | + "pathname": "//path", |
| 6504 | + "search": "", |
| 6505 | + "hash": "" |
| 6506 | + }, |
| 6507 | + { |
| 6508 | + "input": "non-spec:/..//path", |
| 6509 | + "base": "about:blank", |
| 6510 | + "href": "non-spec:/.//path", |
| 6511 | + "protocol": "non-spec:", |
| 6512 | + "username": "", |
| 6513 | + "password": "", |
| 6514 | + "host": "", |
| 6515 | + "hostname": "", |
| 6516 | + "port": "", |
| 6517 | + "pathname": "//path", |
| 6518 | + "search": "", |
| 6519 | + "hash": "" |
| 6520 | + }, |
| 6521 | + { |
| 6522 | + "input": "non-spec:/a/..//path", |
| 6523 | + "base": "about:blank", |
| 6524 | + "href": "non-spec:/.//path", |
| 6525 | + "protocol": "non-spec:", |
| 6526 | + "username": "", |
| 6527 | + "password": "", |
| 6528 | + "host": "", |
| 6529 | + "hostname": "", |
| 6530 | + "port": "", |
| 6531 | + "pathname": "//path", |
| 6532 | + "search": "", |
| 6533 | + "hash": "" |
| 6534 | + }, |
| 6535 | + { |
| 6536 | + "input": "/.//path", |
| 6537 | + "base": "non-spec:/p", |
| 6538 | + "href": "non-spec:/.//path", |
| 6539 | + "protocol": "non-spec:", |
| 6540 | + "username": "", |
| 6541 | + "password": "", |
| 6542 | + "host": "", |
| 6543 | + "hostname": "", |
| 6544 | + "port": "", |
| 6545 | + "pathname": "//path", |
| 6546 | + "search": "", |
| 6547 | + "hash": "" |
| 6548 | + }, |
| 6549 | + { |
| 6550 | + "input": "/..//path", |
| 6551 | + "base": "non-spec:/p", |
| 6552 | + "href": "non-spec:/.//path", |
| 6553 | + "protocol": "non-spec:", |
| 6554 | + "username": "", |
| 6555 | + "password": "", |
| 6556 | + "host": "", |
| 6557 | + "hostname": "", |
| 6558 | + "port": "", |
| 6559 | + "pathname": "//path", |
| 6560 | + "search": "", |
| 6561 | + "hash": "" |
| 6562 | + }, |
| 6563 | + { |
| 6564 | + "input": "..//path", |
| 6565 | + "base": "non-spec:/p", |
| 6566 | + "href": "non-spec:/.//path", |
| 6567 | + "protocol": "non-spec:", |
| 6568 | + "username": "", |
| 6569 | + "password": "", |
| 6570 | + "host": "", |
| 6571 | + "hostname": "", |
| 6572 | + "port": "", |
| 6573 | + "pathname": "//path", |
| 6574 | + "search": "", |
| 6575 | + "hash": "" |
| 6576 | + }, |
| 6577 | + { |
| 6578 | + "input": "a/..//path", |
| 6579 | + "base": "non-spec:/p", |
| 6580 | + "href": "non-spec:/.//path", |
| 6581 | + "protocol": "non-spec:", |
| 6582 | + "username": "", |
| 6583 | + "password": "", |
| 6584 | + "host": "", |
| 6585 | + "hostname": "", |
| 6586 | + "port": "", |
| 6587 | + "pathname": "//path", |
| 6588 | + "search": "", |
| 6589 | + "hash": "" |
| 6590 | + }, |
| 6591 | + { |
| 6592 | + "input": "", |
| 6593 | + "base": "non-spec:/..//p", |
| 6594 | + "href": "non-spec:/.//p", |
| 6595 | + "protocol": "non-spec:", |
| 6596 | + "username": "", |
| 6597 | + "password": "", |
| 6598 | + "host": "", |
| 6599 | + "hostname": "", |
| 6600 | + "port": "", |
| 6601 | + "pathname": "//p", |
| 6602 | + "search": "", |
| 6603 | + "hash": "" |
| 6604 | + }, |
| 6605 | + { |
| 6606 | + "input": "path", |
| 6607 | + "base": "non-spec:/..//p", |
| 6608 | + "href": "non-spec:/.//path", |
| 6609 | + "protocol": "non-spec:", |
| 6610 | + "username": "", |
| 6611 | + "password": "", |
| 6612 | + "host": "", |
| 6613 | + "hostname": "", |
| 6614 | + "port": "", |
| 6615 | + "pathname": "//path", |
| 6616 | + "search": "", |
| 6617 | + "hash": "" |
| 6618 | + }, |
| 6619 | + "Do not serialize /. in path", |
| 6620 | + { |
| 6621 | + "input": "../path", |
| 6622 | + "base": "non-spec:/.//p", |
| 6623 | + "href": "non-spec:/path", |
| 6624 | + "protocol": "non-spec:", |
| 6625 | + "username": "", |
| 6626 | + "password": "", |
| 6627 | + "host": "", |
| 6628 | + "hostname": "", |
| 6629 | + "port": "", |
| 6630 | + "pathname": "/path", |
| 6631 | + "search": "", |
| 6632 | + "hash": "" |
| 6633 | + }, |
6449 | 6634 | "# percent encoded hosts in non-special-URLs",
|
6450 | 6635 | {
|
6451 | 6636 | "input": "non-special://%E2%80%A0/",
|
|
6987 | 7172 | "pathname": "/",
|
6988 | 7173 | "search": "",
|
6989 | 7174 | "hash": "#link"
|
| 7175 | + }, |
| 7176 | + "UTF-8 percent-encode of C0 control percent-encode set and supersets", |
| 7177 | + { |
| 7178 | + "input": "non-special:cannot-be-a-base-url-\u0000\u0001\u001F\u001E\u007E\u007F\u0080", |
| 7179 | + "base": "about:blank", |
| 7180 | + "hash": "", |
| 7181 | + "host": "", |
| 7182 | + "hostname": "", |
| 7183 | + "href": "non-special:cannot-be-a-base-url-%00%01%1F%1E~%7F%C2%80", |
| 7184 | + "origin": "null", |
| 7185 | + "password": "", |
| 7186 | + "pathname": "cannot-be-a-base-url-%00%01%1F%1E~%7F%C2%80", |
| 7187 | + "port": "", |
| 7188 | + "protocol": "non-special:", |
| 7189 | + "search": "", |
| 7190 | + "username": "" |
| 7191 | + }, |
| 7192 | + { |
| 7193 | + "input": "https://www.example.com/path{\u007Fpath.html?query'\u007F=query#fragment<\u007Ffragment", |
| 7194 | + "base": "about:blank", |
| 7195 | + "hash": "#fragment%3C%7Ffragment", |
| 7196 | + "host": "www.example.com", |
| 7197 | + "hostname": "www.example.com", |
| 7198 | + "href": "https://www.example.com/path%7B%7Fpath.html?query%27%7F=query#fragment%3C%7Ffragment", |
| 7199 | + "origin": "https://www.example.com", |
| 7200 | + "password": "", |
| 7201 | + "pathname": "/path%7B%7Fpath.html", |
| 7202 | + "port": "", |
| 7203 | + "protocol": "https:", |
| 7204 | + "search": "?query%27%7F=query", |
| 7205 | + "username": "" |
| 7206 | + }, |
| 7207 | + { |
| 7208 | + "input": "https://user:pass[\u007F@foo/bar", |
| 7209 | + "base": "http://example.org", |
| 7210 | + "hash": "", |
| 7211 | + "host": "foo", |
| 7212 | + "hostname": "foo", |
| 7213 | + "href": "https://user:pass%5B%7F@foo/bar", |
| 7214 | + "origin": "https://foo", |
| 7215 | + "password": "pass%5B%7F", |
| 7216 | + "pathname": "/bar", |
| 7217 | + "port": "", |
| 7218 | + "protocol": "https:", |
| 7219 | + "search": "", |
| 7220 | + "username": "user" |
6990 | 7221 | }
|
6991 | 7222 | ]
|
0 commit comments