21 messages in com.canoo.lists.webtestRE: [Webtest] Yet another XPath Query...
FromSent OnAttachments
Joshua11 Oct 2005 00:09 
Marc Guillemot11 Oct 2005 00:20 
Richard HALLIER11 Oct 2005 01:25 
Marc Guillemot11 Oct 2005 01:44 
Richard HALLIER11 Oct 2005 02:10 
Richard HALLIER11 Oct 2005 02:26 
Marc Guillemot11 Oct 2005 02:42 
Colin O'Brien14 Oct 2005 09:12 
Marc Guillemot17 Oct 2005 00:22 
Colin O'Brien17 Oct 2005 03:43 
Vikenty Menshutkin17 Oct 2005 03:50 
Marc Guillemot17 Oct 2005 03:55 
Colin O'Brien17 Oct 2005 04:38 
Juergen Damke07 Mar 2006 02:34 
Marc Guillemot07 Mar 2006 12:29 
maan07 Mar 2006 23:13 
Juergen Damke08 Mar 2006 02:48 
Marc Guillemot08 Mar 2006 10:56 
maan09 Mar 2006 05:39 
Marc Guillemot09 Mar 2006 11:50 
Marc Guillemot09 Mar 2006 11:52 
Subject:RE: [Webtest] Yet another XPath Query...
From:Vikenty Menshutkin (Vike@oilspace.com)
Date:10/17/2005 03:50:29 AM
List:com.canoo.lists.webtest

Try //tr/td[span/text()='GSMQoSRequested']/../ Instead of //tr/td[span='GSMQoSRequested']/../

-----Original Message----- From: webt@lists.canoo.com [mailto:webt@lists.canoo.com] On Behalf Of Colin O'Brien Sent: Monday, October 17, 2005 2:43 PM To: webt@lists.canoo.com Subject: RE: [Webtest] Yet another XPath Query...

Hi Marc,

I have upgraded to 1.7_R1010 but webtest still does not resolve the XPath as expected... should I pass this on to the gang at jaxen.org...?

Cheers, Colin.

-----Original Message----- From: webt@lists.canoo.com [mailto:webt@lists.canoo.com]On Behalf Of Marc Guillemot Sent: 17 October 2005 08:23 To: webt@lists.canoo.com Subject: Re: [Webtest] Yet another XPath Query...

Hi Colin,

I would recommend first to upgrade to the latest build. The problem you have comes probably from Jaxen and I think that we've upgraded the version used since build 813.

Marc.

Colin O'Brien wrote:

Hi Marc,

For the HTML below I'm using the following xpath to select the very last cell which should evaluate to '0'

//tr/td[span='GSMQoSRequested']/../../../../following-sibling: :tr/td[2]/.

The thing is that, it is evaluated as I expect in XPath Explorer but when I put the same XPath into a storeXPath or verifyXPath step it evaluated to null and my step fails... I'm running with 1.7_R813 at the moment, do I need to upgrade to a later version for better XPath support...? Or is it something I'm overlooking with the XPath syntax...?

Regards, Colin.

************************************************************** **************

* Error Message from canoo: com.canoo.webtest.engine.StepFailedException: xpath test:

//tr/td[span='GSMQoSRequested']/../../../../following-sibling: :tr/td[2]/.

evaluates to: , expected value is: 0, Step: VerifyXPath at D:\canoo\modules\viewCDRDetailsVrfyBlobField.xml:18: with (stepid="Select blob field QoSDelay = 0", text="0",

xpath="//tr/td[span='GSMQoSRequested']/../../../../following-s ibling::tr/td[

2]/.", regex="false", stepType="verifyXPath")

************************************************************** **************

*

************************************************************** **************

* Full XPath Explorer XPath expression: /descendant-or-self::node()/child::tr/child::td[(child::span =

"GSMQoSRequested")]/parent::node()/parent::node()/parent::node ()/parent::nod

e()/following-sibling::tr/child::td[2.0]/self::node()

************************************************************** **************

*

************************************************************** **************

* <tr class="row1"> <td align="left"> <table border="0" cellspacing="0" cellpadding="0"> <tr valign="middle" class="row1"> <td></td> <td><img src="/roambroker/images/menu_bar.gif" alt="" border="0"></td> <td><img src="/roambroker/images/menu_bar.gif" alt="" border="0"></td> <td><img src="/roambroker/images/menu_blank.gif" alt="" border="0"></td>

<td><a href="GetCdrDetails.do?select=8566885&id=1&action=view"><img src="/roambroker/images/menu_tee_minus.gif" alt="Close node" border="0"

</a></td>

<td colspan="3"> <span class="tree-control-unselected-left">GSMQoSRequested</span></td> </tr> </table> </td> <td class="tree-control-unselected-left"></td> </tr> <tr class="row1"> <td align="left"> <table border="0" cellspacing="0" cellpadding="0"> <tr valign="middle" class="row1"> <td></td> <td><img src="/roambroker/images/menu_bar.gif" alt="" border="0"></td> <td><img src="/roambroker/images/menu_bar.gif" alt="" border="0"></td> <td><img src="/roambroker/images/menu_blank.gif" alt="" border="0"></td>

<td><img src="/roambroker/images/menu_bar.gif" alt="" border="0"></td> <td><img src="/roambroker/images/menu_tee.gif" alt="" border="0" </td> <td colspan="2"> <span class="tree-control-unselected-left">QoSDelay</span></td> </tr> </table> </td> <td class="tree-control-unselected-left">0</td> </tr>

************************************************************** **************

*