update link.html test

This commit is contained in:
Halil Durak
2025-10-21 16:49:48 +03:00
parent ba66b7c5db
commit d60d3ebaac

View File

@@ -16,8 +16,8 @@
testing.expectEqual('https://lightpanda.io', link.origin); testing.expectEqual('https://lightpanda.io', link.origin);
link.host = 'lightpanda.io:443'; link.host = 'lightpanda.io:443';
testing.expectEqual('lightpanda.io:443', link.host); testing.expectEqual('lightpanda.io', link.host);
testing.expectEqual('443', link.port); testing.expectEqual('', link.port);
testing.expectEqual('lightpanda.io', link.hostname); testing.expectEqual('lightpanda.io', link.hostname);
link.host = 'lightpanda.io'; link.host = 'lightpanda.io';
@@ -42,9 +42,9 @@
testing.expectEqual('', link.port); testing.expectEqual('', link.port);
link.port = '443'; link.port = '443';
testing.expectEqual('foo.bar:443', link.host); testing.expectEqual('foo.bar', link.host);
testing.expectEqual('foo.bar', link.hostname); testing.expectEqual('foo.bar', link.hostname);
testing.expectEqual('https://foo.bar:443/?q=bar#frag', link.href); testing.expectEqual('https://foo.bar/?q=bar#frag', link.href);
link.port = null; link.port = null;
testing.expectEqual('https://foo.bar/?q=bar#frag', link.href); testing.expectEqual('https://foo.bar/?q=bar#frag', link.href);