Is there a reason you're limiting this to just http and https? What about ftp? I'm not sure there's really a need to test the scheme, is there?