[Webtest] new custom step VerifyProperty added to community web site

Paul King webtest@lists.canoo.com
Fri, 13 Aug 2004 16:40:45 +1000


http://webtest-community.canoo.com/wiki/space/VerifyProperty

As per Marc Guillemot's suggestion I have made a generic
verifyProperty step. Sorry Marc but I haven't made it support
#{lastResp.responseCode} or #{cookie.JSESSION} or
#{header.ContentLength} style syntax at this point.
But I have added StoreHeader and StoreCookie steps
for the time being which I will post shortly.

Cheers, Paul.

-----

VerifyProperty description:

This custom step allows checking of a webtest dynamic property.
This allows properties from storeXXXX commands or variables
changed from scripting functions to be checked.

Example steps (to mimic verifyregex which isn't supported):

<steps>
   <invoke stepid="Load Initial Page" url="/"/>
   <storeregex stepid="extract link target from JavaScript"
     group="1" property="urllocation"
     text=".*name="onClick".*onclick="window.open('(.*)')"/>
   <verifyProperty stepid="check link goes to action not jsp directly"
     property="urllocation" regex="true" text=".*.do"/>
</steps>

Example HTML:

<a href="#" name="onClick" onclick="window.open('myAction.do')">Click 
Here</a>