Home | History | Annotate | Download | only in HTMLAnchorElement
      1 Test setting the port attribute of the URL in HTMLAnchorElement.
      2 
      3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
      4 
      5 
      6 Default port as number
      7 PASS a.href is 'https://www.mydomain.com/path/testurl.html?key=value'
      8 Default port as string
      9 PASS a.href is 'https://www.mydomain.com/path/testurl.html?key=value'
     10 Set port to 0
     11 PASS a.href is 'https://www.mydomain.com:0/path/testurl.html?key=value'
     12 Set port to non-number
     13 PASS a.href is 'https://www.mydomain.com:4/path/testurl.html?key=value'
     14 Set port to null
     15 PASS a.href is 'https://www.mydomain.com:0/path/testurl.html?key=value'
     16 Set port to empty string
     17 PASS a.href is 'https://www.mydomain.com:0/path/testurl.html?key=value'
     18 Set port to undefined
     19 PASS a.href is 'https://www.mydomain.com:0/path/testurl.html?key=value'
     20 Set port to URL with foo: protocol
     21 PASS a.href is 'foo://bar:50/'
     22 PASS successfullyParsed is true
     23 
     24 TEST COMPLETE
     25 
     26