mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-26 17:55:07 +02:00
This is defined in the spec, but was missing in our table. Fix this, and add a spec comment for what is missing. Also begin a basic text based test for URL, so we can get some coverage of LibWeb's usage of URL too.
24 lines
719 B
HTML
24 lines
719 B
HTML
<script src="../include.js"></script>
|
|
<script>
|
|
test(() => {
|
|
function printURL(input) {
|
|
println(input);
|
|
const url = new URL(input);
|
|
println(`protocol => '${url.protocol}'`);
|
|
println(`username => '${url.username}'`);
|
|
println(`password => '${url.password}'`);
|
|
println(`host => '${url.host}'`);
|
|
println(`hostname => '${url.hostname}'`);
|
|
println(`port => '${url.port}'`);
|
|
println(`pathname => '${url.pathname}'`);
|
|
println(`search => '${url.search}'`);
|
|
}
|
|
|
|
for (url of [
|
|
'ftp://serenityos.org:21',
|
|
]) {
|
|
printURL(url);
|
|
}
|
|
});
|
|
</script>
|