1Canonicalization of IPv4 addresses. 2 3On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". 4 5 6FAIL canonicalize('http:///') should be http:. Was http:/. 7PASS canonicalize('http://./') is 'http://./' 8PASS canonicalize('http://192.168.0.1/') is 'http://192.168.0.1/' 9FAIL canonicalize('http://0300.0250.00.01/') should be http://192.168.0.1/. Was http://0300.0250.00.01/. 10FAIL canonicalize('http://0xC0.0Xa8.0x0.0x1/') should be http://192.168.0.1/. Was http://0xC0.0Xa8.0x0.0x1/. 11PASS canonicalize('http://192.168.9.com/') is 'http://192.168.9.com/' 12PASS canonicalize('http://19a.168.0.1/') is 'http://19a.168.0.1/' 13PASS canonicalize('http://0308.0250.00.01/') is 'http://0308.0250.00.01/' 14FAIL canonicalize('http://0xCG.0xA8.0x0.0x1/') should be http://0xcg.0xa8.0x0.0x1/. Was http://0xCG.0xA8.0x0.0x1/. 15FAIL canonicalize('http://192/') should be http://0.0.0.192/. Was http://192/. 16FAIL canonicalize('http://0xC0a80001/') should be http://192.168.0.1/. Was http://0xC0a80001/. 17FAIL canonicalize('http://030052000001/') should be http://192.168.0.1/. Was http://030052000001/. 18FAIL canonicalize('http://000030052000001/') should be http://192.168.0.1/. Was http://000030052000001/. 19FAIL canonicalize('http://192.168/') should be http://192.0.0.168/. Was http://192.168/. 20FAIL canonicalize('http://192.0x00A80001/') should be http://192.168.0.1/. Was http://192.0x00A80001/. 21FAIL canonicalize('http://0xc0.052000001/') should be http://192.168.0.1/. Was http://0xc0.052000001/. 22FAIL canonicalize('http://192.168.1/') should be http://192.168.0.1/. Was http://192.168.1/. 23PASS canonicalize('http://192.168.0.0.1/') is 'http://192.168.0.0.1/' 24FAIL canonicalize('http://192.168.0.1./') should be http://192.168.0.1/. Was http://192.168.0.1./. 25FAIL canonicalize('http://192.168.0.1. hello/') should be http://192.168.0.1.%20hello/. Was http://192.168.0.1. hello/. 26PASS canonicalize('http://192.168.0.1../') is 'http://192.168.0.1../' 27PASS canonicalize('http://192.168..1/') is 'http://192.168..1/' 28PASS canonicalize('http://0x100.0/') is 'http://0x100.0/' 29PASS canonicalize('http://0x100.0.0/') is 'http://0x100.0.0/' 30PASS canonicalize('http://0x100.0.0.0/') is 'http://0x100.0.0.0/' 31PASS canonicalize('http://0.0x100.0.0/') is 'http://0.0x100.0.0/' 32PASS canonicalize('http://0.0.0x100.0/') is 'http://0.0.0x100.0/' 33PASS canonicalize('http://0.0.0.0x100/') is 'http://0.0.0.0x100/' 34PASS canonicalize('http://0.0.0x10000/') is 'http://0.0.0x10000/' 35PASS canonicalize('http://0.0x1000000/') is 'http://0.0x1000000/' 36PASS canonicalize('http://0x100000000/') is 'http://0x100000000/' 37FAIL canonicalize('http://0xFF.0/') should be http://255.0.0.0/. Was http://0xFF.0/. 38FAIL canonicalize('http://0xFF.0.0/') should be http://255.0.0.0/. Was http://0xFF.0.0/. 39FAIL canonicalize('http://0xFF.0.0.0/') should be http://255.0.0.0/. Was http://0xFF.0.0.0/. 40FAIL canonicalize('http://0.0xFF.0.0/') should be http://0.255.0.0/. Was http://0.0xFF.0.0/. 41FAIL canonicalize('http://0.0.0xFF.0/') should be http://0.0.255.0/. Was http://0.0.0xFF.0/. 42FAIL canonicalize('http://0.0.0.0xFF/') should be http://0.0.0.255/. Was http://0.0.0.0xFF/. 43FAIL canonicalize('http://0.0.0xFFFF/') should be http://0.0.255.255/. Was http://0.0.0xFFFF/. 44FAIL canonicalize('http://0.0xFFFFFF/') should be http://0.255.255.255/. Was http://0.0xFFFFFF/. 45FAIL canonicalize('http://0xFFFFFFFF/') should be http://255.255.255.255/. Was http://0xFFFFFFFF/. 46PASS canonicalize('http://276.256.0xf1a2.077777/') is 'http://276.256.0xf1a2.077777/' 47PASS canonicalize('http://192.168.0.257/') is 'http://192.168.0.257/' 48PASS canonicalize('http://192.168.0xa20001/') is 'http://192.168.0xa20001/' 49PASS canonicalize('http://192.015052000001/') is 'http://192.015052000001/' 50FAIL canonicalize('http://0X12C0a80001/') should be http://0x12c0a80001/. Was http://0X12C0a80001/. 51PASS canonicalize('http://276.1.2/') is 'http://276.1.2/' 52FAIL canonicalize('http://192.168.0.1 hello/') should be http://192.168.0.1%20hello/. Was http://192.168.0.1 hello/. 53FAIL canonicalize('http://0000000000000300.0x00000000000000fF.00000000000000001/') should be http://192.255.0.1/. Was http://0000000000000300.0x00000000000000fF.00000000000000001/. 54FAIL canonicalize('http://0000000000000300.0xffffffffFFFFFFFF.3022415481470977/') should be http://0000000000000300.0xffffffffffffffff.3022415481470977/. Was http://0000000000000300.0xffffffffFFFFFFFF.3022415481470977/. 55FAIL canonicalize('http://00000000000000000001/') should be http://0.0.0.1/. Was http://00000000000000000001/. 56PASS canonicalize('http://0000000000000000100000000000000001/') is 'http://0000000000000000100000000000000001/' 57PASS canonicalize('http://0.0.0.000000000000000000z/') is 'http://0.0.0.000000000000000000z/' 58PASS canonicalize('http://0.0.0.100000000000000000z/') is 'http://0.0.0.100000000000000000z/' 59FAIL canonicalize('http://0.00.0x.0x0/') should be http://0.0.0.0/. Was http://0.00.0x.0x0/. 60PASS successfullyParsed is true 61 62TEST COMPLETE 63 64