Fix validation of url protocol in tests