Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

httpunit-1.6 package is not work

10 views
Skip to first unread message

nova...@gmail.com

unread,
Mar 4, 2006, 11:37:09 AM3/4/06
to
I download the package from this site
http://www.httpunit.org/
http://voxel.dl.sourceforge.net/sourceforge/httpunit/httpunit-1.6.zip

I try to run one of examples folder "ProxySample.java"
and i do some changing in setProxyServer with user

import com.meterware.httpunit.WebConversation;
import junit.framework.TestCase;
import junit.framework.TestSuite;

public class ProxySample extends TestCase {
public static void main(String args[]) {
junit.textui.TestRunner.run( suite() );
}
public static TestSuite suite() {
return new TestSuite( ProxySample.class );
}
public ProxySample( String name ) {
super( name );
}
public void testProxyAccess() throws Exception {
WebConversation wc = new WebConversation();
wc.setProxyServer( "stuproxy.kfupm.edu.sa", 80, "UserAccount",
"password" );
wc.getResponse( "http://www.meterware.com" );
}
}

it give me this result

<<<
.E
Time: 0.937
There was 1 error:
1) testProxyAccess(ProxySample)java.lang.RuntimeException: No HTML
parser found.
Make sure that either nekoHTML.jar or Tidy.jar is in the in classpath
at
com.meterware.httpunit.parsing.HTMLParserFactory.getHTMLParser(HTMLPa
rserFactory.java:92)
at com.meterware.httpunit.HTMLPage.parse(HTMLPage.java:255)
at
com.meterware.httpunit.WebResponse.getReceivedPage(WebResponse.java:1
126)
at
com.meterware.httpunit.WebResponse$Scriptable.load(WebResponse.java:6
88)
at
com.meterware.httpunit.javascript.JavaScript.load(JavaScript.java:89)

at
com.meterware.httpunit.javascript.JavaScriptEngineFactory.load(JavaSc
riptEngineFactory.java:58)
at
com.meterware.httpunit.RequestContext.runScripts(RequestContext.java:
44)
at
com.meterware.httpunit.WebWindow.getResponse(WebWindow.java:122)
at
com.meterware.httpunit.WebWindow.getResponse(WebWindow.java:102)
at
com.meterware.httpunit.WebClient.getResponse(WebClient.java:87)
at ProxySample.testProxyAccess(ProxySample.java:53)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at ProxySample.main(ProxySample.java:36)

FAILURES!!!
Tests run: 1, Failures: 0, Errors: 1
>>>

please, can you help me

thanks

Owen Jacobson

unread,
Mar 4, 2006, 4:55:13 PM3/4/06
to
On Sat, 04 Mar 2006 08:37:09 -0800, nova1427 wrote:

> I download the package from this site
> http://www.httpunit.org/
> http://voxel.dl.sourceforge.net/sourceforge/httpunit/httpunit-1.6.zip
>
> I try to run one of examples folder "ProxySample.java"
> and i do some changing in setProxyServer with user

...snip...

> it give me this result
>
> <<<
> .E
> Time: 0.937
> There was 1 error:
> 1) testProxyAccess(ProxySample)java.lang.RuntimeException: No HTML
> parser found.
> Make sure that either nekoHTML.jar or Tidy.jar is in the in classpath

...snip...

>>>>
>
> please, can you help me

READ. THE. ERROR. It tells you exactly what's wrong and how to fix it.

NOVA

unread,
Mar 4, 2006, 11:24:43 PM3/4/06
to
I try and not find the error.

thanks to your reply

0 new messages