Browse Source

test: synchronize WPT url setters tests data

Synchronize url-setter-test to upstream.

Refs: https://github.com/w3c/web-platform-tests/pull/5112
PR-URL: https://github.com/nodejs/node/pull/11887
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
v7.x
Daijiro Wachi 8 years ago
committed by Myles Borins
parent
commit
169f187f16
No known key found for this signature in database GPG Key ID: 933B01F40B5CA946
  1. 51
      test/fixtures/url-setter-tests.json

51
test/fixtures/url-setter-tests.json

@ -111,6 +111,55 @@
"protocol": "http:" "protocol": "http:"
} }
}, },
{
"href": "gopher://example.net:1234",
"new_value": "file",
"expected": {
"href": "gopher://example.net:1234/",
"protocol": "gopher:"
}
},
{
"href": "wss://x:x@example.net:1234",
"new_value": "file",
"expected": {
"href": "wss://x:x@example.net:1234/",
"protocol": "wss:"
}
},
{
"comment": "Can’t switch from file URL with no host",
"href": "file://localhost/",
"new_value": "http",
"expected": {
"href": "file:///",
"protocol": "file:"
}
},
{
"href": "file:///test",
"new_value": "gopher",
"expected": {
"href": "file:///test",
"protocol": "file:"
}
},
{
"href": "file:",
"new_value": "wss",
"expected": {
"href": "file:///",
"protocol": "file:"
}
},
{
"href": "file://hi/path",
"new_value": "s",
"expected": {
"href": "file://hi/path",
"protocol": "file:"
}
},
{ {
"href": "https://example.net", "href": "https://example.net",
"new_value": "s", "new_value": "s",
@ -1177,4 +1226,4 @@
} }
} }
] ]
} }

Loading…
Cancel
Save