Source code
Revision control
Copy as Markdown
Other Tools
{
"name": "Absolute URL addresses",
"tests": {
"should only accept absolute URL addresses with fetch schemes": {
"importMap": {
"imports": {
"about": "about:good",
"blob": "blob:good",
"data": "data:good",
"import": "import:bad",
"mailto": "mailto:bad",
"javascript": "javascript:bad",
"wss": "wss:bad"
}
},
"expectedParsedImportMap": {
"imports": {
"about": "about:good",
"blob": "blob:good",
"data": "data:good",
"import": "import:bad",
"javascript": "javascript:bad",
"mailto": "mailto:bad",
},
"scopes": {}
}
},
"should parse absolute URLs, ignoring unparseable ones": {
"importMap": {
"imports": {
"invalidButParseable1": "https:example.org",
}
},
"expectedParsedImportMap": {
"imports": {
"unparseable2": null,
"unparseable3": null,
},
"scopes": {}
}
}
}
}