[ http://webtest-community.canoo.com/jira/browse/WT-52?page=all ]
     
Paul King closed WT-52:
-----------------------


http://www.manning.com/koenig/

> failing to parse xpath expression with parent node
> --------------------------------------------------
>
>          Key: WT-52
>          URL: http://webtest-community.canoo.com/jira/browse/WT-52
>      Project: WebTest
>         Type: Bug

>  Environment: webtest as of 6/21/2005
> htmlunit-20050621.jar
> jaxen-1.1-beta-6.jar
>     Reporter: jiyun kim
>     Assignee: Denis N. Antonioli
>      Fix For: 2.0

>
> unexpected exception caught when using xpath with reference to parent node
> test script
> <steps>
> <invoke url="test0.html"/>
> <storeXPath xpath="count(//a/img[contains(@src,&quot;gif&quot;)])" 
> property="link.cnt"/>
> <storeXPath                      
> xpath="(//a/img[contains(@src,&quot;gif&quot;)])[#{link.cnt}]/../@href" 
> property="link.href"/>               
> </steps>
> sample html
> <html>
> <head>
> <body>
> <p>Testing for webtest xpath</p>
> <p><a><img src=images/select.gif></a></p>
> <p><a><img src=images/select.gif></a></p>
> </body>
> </html>
> exception 
> BUILD FAILED: 
> Exception raised: com.canoo.webtest.engine.StepExecutionException: Unexpected 
> exception caught: org.jaxen.XPathSyntaxException: Node-set expected, Step: 
> StoreXPath at 
> /Users/jiyunkim/eclipse/workspace/canoo/sample/googletest.xml:41:  with 
> (Property="link.href", -> computed value="null", description="get href of 
> last gif image link", XPath="(//a/img[contains(@src,"gif")])[2]/../@href", 
> stepType="storeXPath")com.canoo.webtest.engine.StepExecutionException: 
> Unexpected exception caught: org.jaxen.XPathSyntaxException: Node-set 
> expected, Step: StoreXPath at 
> /Users/jiyunkim/eclipse/workspace/canoo/sample/googletest.xml:41:  with 
> (Property="link.href", -> computed value="null", description="get href of 
> last gif image link", XPath="(//a/img[contains(@src,"gif")])[2]/../@href", 
> stepType="storeXPath")

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://webtest-community.canoo.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

_______________________________________________
WebTest mailing list
[email protected]
http://lists.canoo.com/mailman/listinfo/webtest

Reply via email to