[Webtest] RE: WebTest digest, Vol 1 #1807 - 3 msgs

Francisco Javier Martin Gutierrez francisco-javier.martin@thalesgroup.com
Fri, 13 Apr 2007 14:42:43 +0200


Please, i have some questions.=20

First, I have this code in my page but I can't follow it:=20

<a href=3D"HistoriaSocialParrillaFamiliar.do?codHS=3D0006008"><img
src=3D"imagenes/ico_familia.gif" alt=3D"Parrilla Socio-familiar" =
border=3D"0"
onclick=3D"cierre=3Dfalse;"></a>

href change each time i goto the page. I have tried to save href xpath =
link
but I have errors. I try:

          <storeXPath	description=3D"Extract href attribute =
from...?????"
			xpath=3D"//a [1]/@href"=09
			property=3D"link" />
or:

          <storeXPath	description=3D"Extract href attribute from =
...?????"
			xpath=3D"//a[@src=3D imagenes/ico_familia.gif]/@href"

			property=3D"link" />
and:

		  <clickLink description=3D"Click Link: Parrilla
Socio-Familiar"
			href=3D"#{link}" />

but any of them work ok.

Second, I need to set Referer option to http 1.1 response, but I always
obtain a message like this:=20

[storeHeader]  INFO (com.canoo.webtest.steps.Step) - Message was: Header
"Referer:" not set!

I make the next steeps:

<project name=3D"SAUSS" basedir=3D"." default=3D"main">
....=09
  <property	name=3D"myReferer" value=3D"http://espinete:7783"  />
....
<target name=3D"main">
    <webtest name=3D"PruebaPc000">
   =20
      <!--Archivo de configuracion-->
      <config	description=3D"respuesta del host, reporting and logging"
		host=3D"espinete"  port=3D"7783"  protocol=3D"http"  basepath=3D""
		summary=3D"true"	saveresponse=3D"true"
saveprefix=3D"PruebaPc000"	resultpath=3D"${webtest.home}/SAUSS/results"
resultfile=3D"resultados.xml"
		haltonerror=3D"false"=09
		autorefresh=3D"true"	showhtmlparseroutput=3D"true"
      >
        <header	name=3D"Referer"  value=3D"${myReferer}"/>=20
        <header	name=3D"User-Agent"	value=3D"MSIE 6.0b"  /> =20
        <header name=3D"Connection"	value=3D"Keep-Alive"  />
	    <header	name=3D"Cache-Control"	value=3D"no-cache" />
      </config>
     =20
      <steps>
		<invoke	description=3D"goto login page" url=3D"sauss" />
   =20
		<storeHeader description=3D"store Referer" name=3D"Referer"
property=3D"myReferer" propertyType=3D"dynamic"/> =20

And the result is an error message and Webtest fail.=20
Please, can somebody get me any help?

Francisco Javier Mart=EDn=20
	=20
	=20
-----Mensaje original-----
De: webtest-admin@lists.canoo.com [mailto:webtest-admin@lists.canoo.com] =
En
nombre de webtest-request@lists.canoo.com
Enviado el: viernes, 13 de abril de 2007 12:01
Para: webtest@lists.canoo.com
Asunto: WebTest digest, Vol 1 #1807 - 3 msgs

Send WebTest mailing list submissions to
	webtest@lists.canoo.com

To subscribe or unsubscribe via the World Wide Web, visit
	http://lists.canoo.com/mailman/listinfo/webtest
or, via email, send a message with subject or body 'help' to
	webtest-request@lists.canoo.com

You can reach the person managing the list at
	webtest-admin@lists.canoo.com

When replying, please edit your Subject line so it is more specific
than "Re: Contents of WebTest digest..."


Today's Topics:

   1. Latest build issue - v (Christopher Colebourn)
   2. Re: Latest build issue - v (Marc Guillemot)
   3. Beginer in Webtest (Shruti Deshpande)

--__--__--

Message: 1
To: webtest@gate2.canoo.com
From: Christopher Colebourn <ccolebou@csc.com>
Date: Thu, 12 Apr 2007 09:30:31 -0400
Subject: [Webtest] Latest build issue - v
Reply-To: webtest@lists.canoo.com
Reply-To: Christopher Colebourn <ccolebou@csc.com>



I have the following element in my page:

      <span id=3D"title" style=3D"display:none; visibility: =
hidden;">Status
Change</span>

The hidden title is specifically used by the web tests to identify what
page is currently displayed (yes, I know we could use the HTML title
element, but we have other requirements for the content of that).

To verify a page title as above I am using:

      <verifyElementText description=3D"Verify the page displayed ok"
htmlId=3D"title" text=3D"Status Change"  />

This worked fine in Canoo 2.1.   I have now downloaded the latest =
version
R_1541 and it fails with the following messages:

[verifyElementText]  INFO (com.canoo.webtest.steps.Step) - >>>> Start =
Step:
verifyElementText "Verify the page displayed ok" (10/12)
[verifyElementText]  INFO (com.canoo.webtest.steps.Step) - Running with:
Canoo Webtest: R_1541.
[verifyElementText]  INFO (com.canoo.webtest.steps.Step) - Exception =
thrown
from this class: com.canoo.webtest.engine.StepFailedException
[verifyElementText]  INFO (com.canoo.webtest.steps.Step) - Message was: =
No
element found with id "title".
 INFO (com.canoo.webtest.steps.Step) - Running with: Canoo Webtest: =
R_1541.
 INFO (com.canoo.webtest.steps.Step) - Exception thrown from this class:
com.canoo.webtest.engine.StepFailedException

So what has changed?   Why is it not finding the element?  Any ideas?


- Chris Colebourn

CSC/FSG Consulting Principal
Email:            ccolebou@csc.com
Phone:            860-221-2442


-------------------------------------------------------------------------=
---
-------------------------------------------------------------------------=
---
------------------------

This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery. NOTE: Regardless of content, this e-mail shall not operate to
bind CSC to any order or other contract unless pursuant to explicit =
written
agreement or government initiative expressly permitting the use of =
e-mail
for such purpose.
-------------------------------------------------------------------------=
---
-------------------------------------------------------------------------=
---
------------------------



--__--__--

Message: 2
Date: Thu, 12 Apr 2007 16:30:59 +0200
From: Marc Guillemot <mguillemot@yahoo.fr>
To: webtest@lists.canoo.com
Subject: Re: [Webtest] Latest build issue - v
Reply-To: webtest@lists.canoo.com
Reply-To: Marc Guillemot <mguillemot@yahoo.fr>

I've made a change yesterday to fix WT-298 with verifyElementText and
added some selftest for that:
http://webtest.canoo.com/webtest/reports/selftest/File12.html

So it seems to work correctly.

Are you sure you're on the right page and that no other change occured
in your app?

Marc.

PS: I think that it is a good practice to add hidden element just to
provide information for the automated tests.

Christopher Colebourn wrote:
>=20
> I have the following element in my page:
>=20
>       <span id=3D"title" style=3D"display:none; visibility: =
hidden;">Status
> Change</span>
>=20
> The hidden title is specifically used by the web tests to identify =
what
> page is currently displayed (yes, I know we could use the HTML title
> element, but we have other requirements for the content of that).
>=20
> To verify a page title as above I am using:
>=20
>       <verifyElementText description=3D"Verify the page displayed ok"
> htmlId=3D"title" text=3D"Status Change"  />
>=20
> This worked fine in Canoo 2.1.   I have now downloaded the latest =
version
> R_1541 and it fails with the following messages:
>=20
> [verifyElementText]  INFO (com.canoo.webtest.steps.Step) - >>>> Start
Step:
> verifyElementText "Verify the page displayed ok" (10/12)
> [verifyElementText]  INFO (com.canoo.webtest.steps.Step) - Running =
with:
> Canoo Webtest: R_1541.
> [verifyElementText]  INFO (com.canoo.webtest.steps.Step) - Exception
thrown
> from this class: com.canoo.webtest.engine.StepFailedException
> [verifyElementText]  INFO (com.canoo.webtest.steps.Step) - Message =
was: No
> element found with id "title".
>  INFO (com.canoo.webtest.steps.Step) - Running with: Canoo Webtest:
R_1541.
>  INFO (com.canoo.webtest.steps.Step) - Exception thrown from this =
class:
> com.canoo.webtest.engine.StepFailedException
>=20
> So what has changed?   Why is it not finding the element?  Any ideas?
>=20
>=20
> - Chris Colebourn
>=20
> CSC/FSG Consulting Principal
> Email:            ccolebou@csc.com
> Phone:            860-221-2442
>=20
>=20
>
-------------------------------------------------------------------------=
---
-------------------------------------------------------------------------=
---
------------------------
>=20
> This is a PRIVATE message. If you are not the intended recipient, =
please
> delete without copying and kindly advise us by e-mail of the mistake =
in
> delivery. NOTE: Regardless of content, this e-mail shall not operate =
to
> bind CSC to any order or other contract unless pursuant to explicit
written
> agreement or government initiative expressly permitting the use of =
e-mail
> for such purpose.
>
-------------------------------------------------------------------------=
---
-------------------------------------------------------------------------=
---
------------------------
>=20
>=20
> _______________________________________________
> WebTest mailing list
> WebTest@lists.canoo.com
> http://lists.canoo.com/mailman/listinfo/webtest
>=20


--__--__--

Message: 3
Date: Fri, 13 Apr 2007 14:14:13 +0530
From: "Shruti Deshpande" <Shruti_Deshpande@symantec.com>
To: <webtest@lists.canoo.com>
Subject: [Webtest] Beginer in Webtest
Reply-To: webtest@lists.canoo.com
Reply-To: "Shruti Deshpande" <Shruti_Deshpande@symantec.com>


This is a multi-part message in MIME format.

------_=3D_NextPart_001_01C77DA7.C0E0F64C
Content-Type: text/plain;
	charset=3D"us-ascii"
Content-Transfer-Encoding: quoted-printable

Hi All,

I would like to use Webtest for the application which is designed using
Struts and tiles.
My question is, how can we compare the results in the webtest for the
tests like click on the link and verify the page which is expected is
displyed or the actul and expected results are same.

Also have any one used webtest for using application developed with
struts and tiles.

Best Wishes,
Shruti Deshpande


------_=3D_NextPart_001_01C77DA7.C0E0F64C
Content-Type: text/html;
	charset=3D"us-ascii"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D3D"Content-Type" CONTENT=3D3D"text/html; =3D
charset=3D3Dus-ascii">
<META NAME=3D3D"Generator" CONTENT=3D3D"MS Exchange Server version =3D
6.5.7638.1">
<TITLE>Beginer in Webtest</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/rtf format -->

<P><FONT SIZE=3D3D2 FACE=3D3D"Arial">Hi All,</FONT>
</P>

<P><FONT SIZE=3D3D2 FACE=3D3D"Arial">I would like to use Webtest for the =
=3D
application which is designed using Struts and tiles.</FONT>

<BR><FONT SIZE=3D3D2 FACE=3D3D"Arial">My question is, how can we compare =
the =3D
results in the webtest for the tests like click on the link and verify =
=3D
the page which is expected is displyed or the actul and expected results =
=3D
are same.</FONT></P>

<P><FONT SIZE=3D3D2 FACE=3D3D"Arial">Also have any one used webtest for =
=3D
using application developed with struts and tiles.</FONT>
</P>

<P><FONT SIZE=3D3D2 FACE=3D3D"Arial">Best Wishes,</FONT>

<BR><FONT SIZE=3D3D2 FACE=3D3D"Arial">Shruti Deshpande</FONT>
</P>

</BODY>
</HTML>
------_=3D_NextPart_001_01C77DA7.C0E0F64C--


--__--__--

_______________________________________________
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.