[Webtest] verifyXPath fails on R_882

Denis N. Antonioli webtest@lists.canoo.com
Fri, 24 Jun 2005 20:02:16 +0200


Hi Tim

indeed, when I insert a new line in my test document, the test fails  
too.

Now is time to go look at the specification, see how it should  
behave ;-)

Nice weekend
     dna


On 24 juin 05, at 17:52, Tim Miller wrote:

> Denis,
>
> I pulled the following out of the actual page. I noticed that there  
> is a
> return before the '76071-1' value. Could this be causing a problem?
>
>
> Order and Analysis summary for each line item in the order:<BR>
> <table border="1" cellspacing="0" cellpadding="1">
>   <tr>
>     <th>OrdLineNum</th>
>     <th>ProdId</th>
>
>     <th>ProdDesc</th>
>     <th>Ndc</th>
>     <th>OrdQty</th>
>     <th>UnitPrice</th>
>     <th>MinOrdQty</th>
>     <th>OrdUnitQty</th>
>
>     <th>EdgeRecCode</th>
>     <th>EdgeRecQty</th>
>     <th>EdgeRndRecQty</th>
>     <th>EdgeRecMethod</th>
>   </tr>
>   <tr>
>     <td>
>
>       76071-1
>     </td>
>     <td>
>       76071
>     </td>
>     <td>
>       Prestall Ap 100mg
>     </td>
>     <td>
>       90543300071
>     </td>
>
>     <td>
>       1000
>     </td>
>     <td>
>       179.17
>     </td>
>     <td>
>       0
>     </td>
>     <td>
>
>       1
>     </td>
>     <td>
>       NR
>     </td>
>     <td>
>       1000
>     </td>
>     <td>
>       1000
>     </td>
>
>     <td>
>       NA
>     </td>
>   </tr>
> </table><BR>
>
>
>
> -----Original Message-----
> From: webtest-admin@lists.canoo.com
> [mailto:webtest-admin@lists.canoo.com] On Behalf Of Denis N. Antonioli
> Sent: Friday, June 24, 2005 6:45 AM
> To: webtest@lists.canoo.com
> Subject: Re: [Webtest] verifyXPath fails on R_882
>
> Hi Tim
>
> I tried to reproduce your bug with following minimal html page:
>
> <html><body>
>      <table>
>          <tr><td>1.1</td><td>1.2</td><td>1.3</td></tr>
>          <tr><td>2.1</td><td>2.2</td><td>2.3</td></tr>
>      </table>
> </body></html>
>
> And the parameters
> xpath = "//tr[td='2.1'][td='2.1']/td[3]"
> text =  "2.3"
>
>
> To no avail, the it doesn't break.
>
> How does your html page differ from the simple version I'm using?
>
> Best
>      dna
>
>
> On 24 juin 05, at 01:59, Tim Miller wrote:
>
>
>> Any idea why verifyXPath does not work when moving from R_825 to
>> R_882? All of my verifyXPath steps now fail.  The only thing that
>> changed was the WebTest version. Below is one sample step.
>>
>>
>>
>> <verifyXPath description="Check for Product Description in table row"
>>
>>   xpath="//tr[td='${alert.ord.line.num}'][td='${alert.prod.id}']/td
>> [3]"
>>
>>   text="${alert.prod.desc}" />
>>
>>
>>
>>
>>
>> Output TestResultOverview.html:
>>
>>
>>
>> com.canoo.webtest.engine.StepFailedException: xpath test: //tr
>> [td='76071-1'][td='76071']/td[3] evaluates to: , expected value is:
>> Prestall Ap 100mg, Step: VerifyXPath at C:\tools\WebTestSuite\gm-
>> scenario\scenario-867-852-001\VerifySecondPurchaseOrderTest.xml:38:
>> with (text="Prestall Ap 100mg", description="Check for Product
>> Description in table row", xpath="//tr[td='76071-1'][td='76071']/td
>> [3]", stepType="verifyXPath")
>>
>
> -- 
> I have no respect for a man who can only spell a word one way.
>    -- Mark Twain
>
> _______________________________________________
> 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
>

-- 
A computer scientist is someone who, when told to "Go to Hell,"
sees the "go to," rather than the destination, as harmful.
   -- Dr. Roger M. Firestone, rfire@cais.cais.com