Using Java, how can I test that a URL is contactable, and returns a valid response?
http://stackoverflow.com/about
System.out.println(new InetSocketAddress("http://stackoverflow.com/about", 80).isUnresolved());
delivers false if page is reachable, which is a precondition.
In order to cover initial question completely, you need to implement a http get or post.