Skip to content

Commit 67f92ae

Browse files
anonriggithub-actions[bot]
authored andcommitted
test: update web platform tests
1 parent 7e1594b commit 67f92ae

File tree

3 files changed

+145
-19
lines changed

3 files changed

+145
-19
lines changed

tests/wpt/setters_tests.json

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2241,38 +2241,38 @@
22412241
}
22422242
},
22432243
{
2244-
"comment": "Drop trailing spaces from trailing opaque paths",
2244+
"comment": "Trailing spaces and opaque paths",
22452245
"href": "data:space ?query",
22462246
"new_value": "",
22472247
"expected": {
2248-
"href": "data:space",
2249-
"pathname": "space",
2248+
"href": "data:space%20",
2249+
"pathname": "space%20",
22502250
"search": ""
22512251
}
22522252
},
22532253
{
22542254
"href": "sc:space ?query",
22552255
"new_value": "",
22562256
"expected": {
2257-
"href": "sc:space",
2258-
"pathname": "space",
2257+
"href": "sc:space%20",
2258+
"pathname": "space%20",
22592259
"search": ""
22602260
}
22612261
},
22622262
{
2263-
"comment": "Do not drop trailing spaces from non-trailing opaque paths",
2263+
"comment": "Trailing spaces and opaque paths",
22642264
"href": "data:space ?query#fragment",
22652265
"new_value": "",
22662266
"expected": {
2267-
"href": "data:space #fragment",
2267+
"href": "data:space %20#fragment",
22682268
"search": ""
22692269
}
22702270
},
22712271
{
22722272
"href": "sc:space ?query#fragment",
22732273
"new_value": "",
22742274
"expected": {
2275-
"href": "sc:space #fragment",
2275+
"href": "sc:space %20#fragment",
22762276
"search": ""
22772277
}
22782278
},
@@ -2429,38 +2429,38 @@
24292429
}
24302430
},
24312431
{
2432-
"comment": "Drop trailing spaces from trailing opaque paths",
2432+
"comment": "Trailing spaces and opaque paths",
24332433
"href": "data:space #fragment",
24342434
"new_value": "",
24352435
"expected": {
2436-
"href": "data:space",
2437-
"pathname": "space",
2436+
"href": "data:space %20",
2437+
"pathname": "space %20",
24382438
"hash": ""
24392439
}
24402440
},
24412441
{
24422442
"href": "sc:space #fragment",
24432443
"new_value": "",
24442444
"expected": {
2445-
"href": "sc:space",
2446-
"pathname": "space",
2445+
"href": "sc:space %20",
2446+
"pathname": "space %20",
24472447
"hash": ""
24482448
}
24492449
},
24502450
{
2451-
"comment": "Do not drop trailing spaces from non-trailing opaque paths",
2451+
"comment": "Trailing spaces and opaque paths",
24522452
"href": "data:space ?query#fragment",
24532453
"new_value": "",
24542454
"expected": {
2455-
"href": "data:space ?query",
2455+
"href": "data:space %20?query",
24562456
"hash": ""
24572457
}
24582458
},
24592459
{
24602460
"href": "sc:space ?query#fragment",
24612461
"new_value": "",
24622462
"expected": {
2463-
"href": "sc:space ?query",
2463+
"href": "sc:space %20?query",
24642464
"hash": ""
24652465
}
24662466
},

tests/wpt/toascii.json

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
[
22
"This contains assorted IDNA tests that IdnaTestV2 might not cover.",
33
"Feel free to deduplicate with a clear commit message.",
4+
"",
5+
"If the test only applies to the URL Standard's 'domain to ASCII', ",
6+
"and not to TR46's ToASCII, then tag it with `urlStandardOnly`",
47
{
58
"comment": "Label with hyphens in 3rd and 4th position",
69
"input": "aa--",
@@ -239,19 +242,22 @@
239242
},
240243
{
241244
"input": "www.lookout.net\u2A7480",
242-
"output": null
245+
"output": null,
246+
"urlStandardOnly": true
243247
},
244248
{
245249
"input": "www\u00A0.lookout.net",
246-
"output": null
250+
"output": null,
251+
"urlStandardOnly": true
247252
},
248253
{
249254
"input": "\u1680lookout.net",
250255
"output": null
251256
},
252257
{
253258
"input": "\u001flookout.net",
254-
"output": null
259+
"output": null,
260+
"urlStandardOnly": true
255261
},
256262
{
257263
"input": "look\u06DDout.net",

tests/wpt/urltestdata.json

Lines changed: 120 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3778,6 +3778,126 @@
37783778
"search": "",
37793779
"hash": ""
37803780
},
3781+
{
3782+
"input": "non-special:opaque ",
3783+
"base": null,
3784+
"href": "non-special:opaque",
3785+
"origin": "null",
3786+
"protocol": "non-special:",
3787+
"username": "",
3788+
"password": "",
3789+
"host": "",
3790+
"hostname": "",
3791+
"port": "",
3792+
"pathname": "opaque",
3793+
"search": "",
3794+
"hash": ""
3795+
},
3796+
{
3797+
"input": "non-special:opaque ?hi",
3798+
"base": null,
3799+
"href": "non-special:opaque %20?hi",
3800+
"origin": "null",
3801+
"protocol": "non-special:",
3802+
"username": "",
3803+
"password": "",
3804+
"host": "",
3805+
"hostname": "",
3806+
"port": "",
3807+
"pathname": "opaque %20",
3808+
"search": "?hi",
3809+
"hash": ""
3810+
},
3811+
{
3812+
"input": "non-special:opaque #hi",
3813+
"base": null,
3814+
"href": "non-special:opaque %20#hi",
3815+
"origin": "null",
3816+
"protocol": "non-special:",
3817+
"username": "",
3818+
"password": "",
3819+
"host": "",
3820+
"hostname": "",
3821+
"port": "",
3822+
"pathname": "opaque %20",
3823+
"search": "",
3824+
"hash": "#hi"
3825+
},
3826+
{
3827+
"input": "non-special:opaque x?hi",
3828+
"base": null,
3829+
"href": "non-special:opaque x?hi",
3830+
"origin": "null",
3831+
"protocol": "non-special:",
3832+
"username": "",
3833+
"password": "",
3834+
"host": "",
3835+
"hostname": "",
3836+
"port": "",
3837+
"pathname": "opaque x",
3838+
"search": "?hi",
3839+
"hash": ""
3840+
},
3841+
{
3842+
"input": "non-special:opaque x#hi",
3843+
"base": null,
3844+
"href": "non-special:opaque x#hi",
3845+
"origin": "null",
3846+
"protocol": "non-special:",
3847+
"username": "",
3848+
"password": "",
3849+
"host": "",
3850+
"hostname": "",
3851+
"port": "",
3852+
"pathname": "opaque x",
3853+
"search": "",
3854+
"hash": "#hi"
3855+
},
3856+
{
3857+
"input": "non-special:opaque \t\t \t#hi",
3858+
"base": null,
3859+
"href": "non-special:opaque %20#hi",
3860+
"origin": "null",
3861+
"protocol": "non-special:",
3862+
"username": "",
3863+
"password": "",
3864+
"host": "",
3865+
"hostname": "",
3866+
"port": "",
3867+
"pathname": "opaque %20",
3868+
"search": "",
3869+
"hash": "#hi"
3870+
},
3871+
{
3872+
"input": "non-special:opaque \t\t #hi",
3873+
"base": null,
3874+
"href": "non-special:opaque %20#hi",
3875+
"origin": "null",
3876+
"protocol": "non-special:",
3877+
"username": "",
3878+
"password": "",
3879+
"host": "",
3880+
"hostname": "",
3881+
"port": "",
3882+
"pathname": "opaque %20",
3883+
"search": "",
3884+
"hash": "#hi"
3885+
},
3886+
{
3887+
"input": "non-special:opaque\t\t \r #hi",
3888+
"base": null,
3889+
"href": "non-special:opaque %20#hi",
3890+
"origin": "null",
3891+
"protocol": "non-special:",
3892+
"username": "",
3893+
"password": "",
3894+
"host": "",
3895+
"hostname": "",
3896+
"port": "",
3897+
"pathname": "opaque %20",
3898+
"search": "",
3899+
"hash": "#hi"
3900+
},
37813901
"Ideographic full stop (full-width period for Chinese, etc.) should be treated as a dot. U+3002 is mapped to U+002E (dot)",
37823902
{
37833903
"input": "http://www.foo。bar.com",

0 commit comments

Comments
 (0)