[Webtest] 1. Re: store link parameter (FJMartin)

Francisco Javier Martin Gutierrez francisco-javier.martin@thalesgroup.com
Wed, 22 Aug 2007 13:22:14 +0200


Hello:

Perhaps the code is not very nice but it works. I only can say that
developer do they want and can. The web application is very big and has =
a
lot of details.

Anyway, the link is available and can be pressed by clickLink:
<clickLink description=3D"Reserva de HS N=BA=3D #{codigoTitular}"
href=3D"BuzonesTareas.do?codProcesoRes=3D" label=3D"Reservar"/>
(It is true that I could not select the link I click on but I know how =
to
obtain that only this kind of link appears on the page. So, if I can =
store
previously this value I could later use it to make other tests).=20

Then the page is reloaded and the link changes to:
<a
href=3D"BuzonesTareas.do?codProcesoLib=3D06782352FBA37F4DAB94C63AD72D5811=
"><img
src=3D"imagenes/mesa_trabajo/ico_candado_abierto.gif" alt=3D"Liberar" =
width=3D"16"
height=3D"15"></a>
=20
It can be reached by XPath but the number is different for each item so =
I
need to store it to test it later.

<verifyXPath
xpath=3D"//a[@href=3D'BuzonesTareas.do?codProcesoLib=3D06782352FBA37F4DAB=
94C63AD72
D5811']" />

I thought that I could store only the number doing something seemed to
storeRegEx example but it does not work. I looked for a special Perl
character to replace the number that has to be stored but these =
characters
like '\w' or '.' do not work properly with verifyXPath command. There is =
not
possibility to replace characters using special Perl characters so, what =
can
I do?

<verifyXPath
xpath=3D"//a[@href=3D'BuzonesTareas.do?codProcesoLib=3D..................=
.........
....." />

I would be very pleased if you can open a Jira issue about (or should I =
do
it?) =20

Thank you again Marc.

-------

Today's Topics:

   1. Re: store link parameter (Marc Guillemot)

Message: 1
Date: Wed, 22 Aug 2007 10:05:12 +0200
From: Marc Guillemot <mguillemot@yahoo.fr>
To: webtest@lists.canoo.com
Subject: Re: [Webtest] store link parameter
Reply-To: webtest@lists.canoo.com
Reply-To: Marc Guillemot <mguillemot@yahoo.fr>

Hi Francisco,

storeLinkParameter doesn't have the link identification possibilities
that clickLink has. I don't know if this would help in your case but
this is surely worth a Jira issue.

Link included in link?!? What a nice html code! ;-(

In the mean time there is surely a workaround with a script step. How
would you identify this link?

Marc.
--=20
Blog: http://mguillem.wordpress.com


Francisco Javier Martin Gutierrez wrote:
> Hello:
>=20
> =20
>=20
> I need to store a link parameter but html id is not available and =
there
> is more than one link similar on the page. The link is:
>=20
> <a
>
href=3D"BuzonesTareas.do?codProcesoRes=3D164678CAA147834AA284A08444B1F77E=
"><img
> src=3D"imagenes/mesa_trabajo/ico_reserva.gif" alt=3D"Reservar" =
width=3D"9"
> height=3D"9"></a>
>=20
> =20
>=20
> And it is included into other link:
>=20
> =20
>=20
> <a
>
href=3D"EditarHistoriaSocial.do?codHistoria=3D0009033&codPrestacion=3D101=
01A&secPr
estacion=3D2&estadoPrestacion=3D11"
> target=3D"0009033">
>=20
>                 <tr class=3D"mesaTxtTabla">      =20
>=20
>                     <td style=3D"cursor:hand"><a
>
href=3D"BuzonesTareas.do?codProcesoRes=3D164678CAA147834AA284A08444B1F77E=
"><img
> src=3D"imagenes/mesa_trabajo/ico_reserva.gif" alt=3D"Reservar" =
width=3D"9"
> height=3D"9"></a></td>
>=20
>                     <td style=3D"cursor:hand">0009033</td>
>=20
>                     <td style=3D"cursor:hand">
>=20
>                         11 - EN ESTUDIO
>=20
>                     </td>
>=20
>                     <td style=3D"cursor:hand">
>=20
>                        Inf. Tel=E9fono del Alzheimer
>=20
>                     </td>
>=20
>                     <td style=3D"cursor:hand">
>=20
>                         AUTOMATICA 017
>=20
>                     </td>
>=20
>                     <td style=3D"cursor:hand">
>=20
>                         PRUEBAPC013 SC
>=20
>                     </td>
>=20
>                     </tr>
>=20
>               </a>
>=20
> The number to store is after codProcesoRes
> (164678CAA147834AA284A08444B1F77E).
>=20
> =20
>=20
> There is any other way to do this? Could it be a jira issue? Thank =
you.
>=20
> =20
>=20
> *Francisco Javier Mart=EDn *
> Desarrollo de Proyectos - Valladolid
> *Security Solutions & Services Division *
>=20
> *Edif. Solar, Of. 13, 14, 15
> Parque Tecnol=F3gico Boecillo. *47151 Valladolid. Espa=F1a
> Tel.: *983 54 65 55   *Fax: *983 54 66 09*
>=20



--__--__--

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


End of WebTest Digest


AVISO LEGAL: La informacion contenida en este mensaje y cualquier documen=
to adjunto en el mismo es confidencial, puede estar legalmente protegida =
y esta dirigida solamente al destinatario. La publicacion, uso, distribuc=
ion, impresion o copia no autorizada del contenido de este mensaje, esta =
estrictamente prohibida y puede ser ilegal. Si Vd. ha recibido este mensa=
je por error, le rogamos destruya el mensaje y lo notifique al remitente =
o llame al telefono (+34) 91 556 92 62.

DISCLAIMER: The information contained in this message and any attached do=
cument is confidential, covered by law and intended solely for the recipi=
ent. The distribution, print, publication, unauthorised copy and / or use=
 of the message content is strictly forbidden and could be deemed illegal=
. If you are not the intended recipient of this message, we request that =
you destroy it and notify the sender either in writing or by calling ++34=
 91 556 92 62.