Getting java.io.IOException when running JUnit test case in Eclipse -
Getting java.io.IOException when running JUnit test case in Eclipse -
here's code
public class jwebunittest extends webtestcase { public jwebunittest(string name) { super(name); } public void setup() { gettestcontext().setbaseurl("http://www.google.com"); } public void testsearch() { beginat("/"); setformelement("q", "httpunit"); submit("btng"); clicklinkwithtext("httpunit"); asserttitleequals("httpunit"); assertlinkpresentwithtext("user's manual"); } }
in failure trace, see next error:
java.lang.runtimeexception: java.io.ioexception (moving down..) caused by: java.net.socketexception: operation timed out: connect: due invalid address
why "http://www.google.com/" invalid address? why getting ioexception?
i suggest seek of these options
1.) clean project 1 time . project - clean (in eclipse) , rebuild
2.) seek updating eclipse latest version
3.) seek nail localhost server (this show whether theres problem ur code or eclipse)
4.) should needing proxy. configure accordingly
junit ioexception testcase jwebunit
Comments
Post a Comment