[Webtest] Re: Error org.apache.xerces.xni.XNIException

Moynihan, Michael A Moynihan, Michael A" <Michael.A.Moynihan@Fmr.com
Thu, 3 May 2007 08:35:07 -0400


Ok, I solved the problem outlined below.

I had to add the following jars to my ant/lib directory.

ant-contrib-0.6.jar
commons-net-1.0.0.jar
jdepend-2.9.1.jar
jsch-0-1.30.jar
junit.jar

I'm not sure which specific one solved the problem but I can now run my
tests which any parsing errors.

Thanks,

Michael =20

-----Original Message-----
From: webtest-admin@gate2.canoo.com
[mailto:webtest-admin@gate2.canoo.com] On Behalf Of Moynihan, Michael A
Sent: Tuesday, May 01, 2007 11:39 PM
To: webtest@gate2.canoo.com; Marc Guillemot
Subject: RE: [Webtest] Re: Error org.apache.xerces.xni.XNIException

Ya that's what I was thinking but I'm unable to find the conflict.=20

I removed any unnecessary components from my classpath environment
variable and the error still exists.

I upgraded my canoo version to the latest build. When I run the tests
now I get an error parsing the HTML which is returned from the app.

I tried with my JAVA_HOME set to JDK 1.4 and 1.5.

Anyone have any ideas?

Any help greatly appreciated.

Thanks,

Michael


BUILD FAILED
C:\vwstore\a343909_jil-2.0_snapshot\vobs\test\canoo\MyApp\canoo.xml:49:
Canoo Webtest: R_1546.
Test failed.
Exception raised: java.lang.RuntimeException: Failed parsing content
from http:/
/localhost:9081/AccountViewerAdvanced/sample/startjava.lang.RuntimeExcep
tion: Fa
iled parsing content from http://localhost:9080/MyApp/start
        at
com.gargoylesoftware.htmlunit.html.HTMLParser.parse(HTMLParser.java:2
34)
        at
com.gargoylesoftware.htmlunit.DefaultPageCreator.createHtmlPage(Defau
ltPageCreator.java:112)
        at
com.gargoylesoftware.htmlunit.DefaultPageCreator.createPage(DefaultPa
geCreator.java:85)
        at
com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient
.java:441)
        at
com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:345)
        at
com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:399)
        at
com.canoo.webtest.steps.request.TargetHelper.getResponse(TargetHelper
.java:69)
        at
com.canoo.webtest.steps.request.AbstractTargetAction.getResponse(Abst
ractTargetAction.java:68)
        at
com.canoo.webtest.steps.request.InvokePage.findTarget(InvokePage.java
:134)
        at
com.canoo.webtest.steps.request.AbstractTargetAction$1.call(AbstractT
argetAction.java:108)
        at
com.canoo.webtest.steps.request.TargetHelper.protectedGoto(TargetHelp
er.java:88)
        at
com.canoo.webtest.steps.request.AbstractTargetAction.gotoTarget(Abstr
actTargetAction.java:106)
        at
com.canoo.webtest.steps.request.AbstractTargetAction.doExecute(Abstra
ctTargetAction.java:78)
        at com.canoo.webtest.steps.Step.execute(Step.java:104)
        at
org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
        at org.apache.tools.ant.Task.perform(Task.java:364)
        at
com.canoo.webtest.ant.TestStepSequence.executeSteps(TestStepSequence.
java:43)
     =20


-----Original Message-----
From: webtest-admin@gate2.canoo.com
[mailto:webtest-admin@gate2.canoo.com] On Behalf Of Marc Guillemot
Sent: Tuesday, May 01, 2007 11:45 AM
To: webtest@gate2.canoo.com
Subject: [Webtest] Re: Error org.apache.xerces.xni.XNIException

Hi,

looks like a classpath problem. I guess that you have some conflicting
jars in your CLASSPATH or in your JRE.

Any particular reason to use 2.0? Besides numerous other improvements,
the latest build would give you more information on the cause of the
XNIException.

Marc.

Moynihan, Michael A wrote:
> Hi,
>=20
> I'm using Canoo Webtest 2.0. When I try to kick off my canoo tests I
get
> the following error
>=20
>  [testSpec] org.apache.xerces.xni.XNIException
>  [testSpec]     at
> org.cyberneko.html.HTMLScanner$ContentScanner.scan(HTMLScanne
> r.java:1860)
>  [testSpec]     at
> org.cyberneko.html.HTMLScanner.scanDocument(HTMLScanner.java:
> 789)
>  [testSpec]     at
> org.cyberneko.html.HTMLConfiguration.parse(HTMLConfiguration.
> java:478)
>  [testSpec]     at
> org.cyberneko.html.HTMLConfiguration.parse(HTMLConfiguration.
> java:431)
>  [testSpec]     at org.apache.xerces.parsers.XMLParser.parse(Unknown
> Source)
>  [testSpec]     at
> com.gargoylesoftware.htmlunit.html.HTMLParser$HtmlUnitDOMBuil
> der.parse(HTMLParser.java:330)
>  [testSpec]     at
> com.gargoylesoftware.htmlunit.html.HTMLParser.parse(HTMLParse
>=20
> When it tries to parse an xml page.
>=20
> My installation of canoo seems to be ok because when I run the
> installation verifier
>=20
>         ant -buildfile installText.xml from the doc/samples folder
>=20
> the build is successful.
>=20
> Does anyone know why I'm getting an xerces exception? I'm using JDK1.4
> and the xml file that throws the error works fine for other colleagues
> of mine. It must be a problem specific to my environment but can
anyone
> think what?
>=20
> Thanking you in advance,
>=20
> Michael
>=20
>=20
>=20
>=20

_______________________________________________
WebTest mailing list
WebTest@lists.canoo.com
http://lists.canoo.com/mailman/listinfo/webtest

_______________________________________________
WebTest mailing list
WebTest@lists.canoo.com
http://lists.canoo.com/mailman/listinfo/webtest