|
102 | 102 | }
|
103 | 103 | },
|
104 | 104 | {
|
105 |
| - "comment": "Spec deviation: from special scheme to not is not problematic. https://github.com/whatwg/url/issues/104", |
| 105 | + "comment": "Can’t switch from special scheme to non-special. Note: this may change, see https://github.com/whatwg/url/issues/104", |
106 | 106 | "href": "http://example.net",
|
107 | 107 | "new_value": "b",
|
108 | 108 | "expected": {
|
109 |
| - "href": "b://example.net/", |
110 |
| - "protocol": "b:" |
| 109 | + "href": "http://example.net/", |
| 110 | + "protocol": "http:" |
111 | 111 | }
|
112 | 112 | },
|
113 | 113 | {
|
|
120 | 120 | }
|
121 | 121 | },
|
122 | 122 | {
|
123 |
| - "comment": "Spec deviation: from non-special scheme with a host to special is not problematic. https://github.com/whatwg/url/issues/104", |
| 123 | + "comment": "Can’t switch from non-special scheme to special. Note: this may change, see https://github.com/whatwg/url/issues/104", |
124 | 124 | "href": "ssh://[email protected]",
|
125 | 125 | "new_value": "http",
|
126 | 126 | "expected": {
|
127 |
| - "href": "http://[email protected]/", |
128 |
| - "protocol": "http:" |
| 127 | + "href": "ssh://[email protected]/", |
| 128 | + "protocol": "ssh:" |
129 | 129 | }
|
130 | 130 | },
|
131 | 131 | {
|
|
346 | 346 | }
|
347 | 347 | },
|
348 | 348 | {
|
349 |
| - "comment": "Spec deviation: port number is removed if empty in the new value: https://github.com/whatwg/url/pull/113", |
| 349 | + "comment": "Port number is unchanges if empty in the new value. Note: this may change, see https://github.com/whatwg/url/pull/113", |
350 | 350 | "href": "http://example.net:8080",
|
351 | 351 | "new_value": "example.com:",
|
352 | 352 | "expected": {
|
353 |
| - "href": "http://example.com/", |
354 |
| - "host": "example.com", |
| 353 | + "href": "http://example.com:8080/", |
| 354 | + "host": "example.com:8080", |
355 | 355 | "hostname": "example.com",
|
356 |
| - "port": "" |
| 356 | + "port": "8080" |
357 | 357 | }
|
358 | 358 | },
|
359 | 359 | {
|
|
761 | 761 | }
|
762 | 762 | },
|
763 | 763 | {
|
764 |
| - "comment": "Spec deviation: port number is removed if empty in the new value. https://github.com/whatwg/url/pull/113", |
| 764 | + "comment": "Port number is unchanged if empty in the new value. Note: this may change, see https://github.com/whatwg/url/pull/113", |
765 | 765 | "href": "http://example.net:8080",
|
766 | 766 | "new_value": "",
|
767 | 767 | "expected": {
|
768 |
| - "href": "http://example.net/", |
769 |
| - "host": "example.net", |
| 768 | + "href": "http://example.net:8080/", |
| 769 | + "host": "example.net:8080", |
770 | 770 | "hostname": "example.net",
|
771 |
| - "port": "" |
| 771 | + "port": "8080" |
772 | 772 | }
|
773 | 773 | },
|
774 | 774 | {
|
|
0 commit comments