Skip to content

Commit

Permalink
test: check the origin of the blob URLs
Browse files Browse the repository at this point in the history
In the getter of the origin in URL, the URL that has blob protocol
will be parsed in a function called "originFor".
Add test cases into the url-tests-additional fixture to test that.

Refs: web-platform-tests/wpt#4941

PR-URL: nodejs/node#11426
Reviewed-By: Joyee Cheung <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Timothy Gu <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
watilde committed Mar 5, 2017
1 parent 70beef9 commit 39f7e72
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions test/fixtures/url-tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -5622,5 +5622,33 @@ module.exports =
"input": "non-special://[:80/",
"base": "about:blank",
"failure": true
},
{
"input": "blob:https://example.com:443/",
"base": "about:blank",
"href": "blob:https://example.com:443/",
"protocol": "blob:",
"username": "",
"password": "",
"host": "",
"hostname": "",
"port": "",
"pathname": "https://example.com:443/",
"search": "",
"hash": ""
},
{
"input": "blob:d3958f5c-0777-0845-9dcf-2cb28783acaf",
"base": "about:blank",
"href": "blob:d3958f5c-0777-0845-9dcf-2cb28783acaf",
"protocol": "blob:",
"username": "",
"password": "",
"host": "",
"hostname": "",
"port": "",
"pathname": "d3958f5c-0777-0845-9dcf-2cb28783acaf",
"search": "",
"hash": ""
}
]

0 comments on commit 39f7e72

Please sign in to comment.