[Webtest] WebTest digest
Marc Guillemot
Marc Guillemot <mguillemot@yahoo.fr>
Thu, 12 Apr 2007 09:39:57 +0200
Hi,
the redirect message only tells that redirects are not handled by
commons-httpclient. This is normal because they are handled one level
upper: by htmlunit. In all cases you don't have to do anything
concerning it.
To understand what happens, you need to look at the log (maybe setting
it to debug level) after your click on the button.
Marc.
Btw: js is enabled by default, you don't need <enableJavascript.../> here
Francisco Javier Martin Gutierrez wrote:
> Hello:
>
> I have a problem when i clickButton over a script java page.
> Previous response is: .../NuevoCaso.do
> and next response is: .../NuevoCaso.do
>
> I think that I need to store header properties or to enable
> followRedirects because I obtain this info message:
>
> [invoke] INFO (com.canoo.webtest.steps.request.TargetHelper) - getting
> response for url: http://espinete:7783/sauss
> [invoke] INFO (org.apache.commons.httpclient.HttpMethodDirector) - Redirect
> requested but followRedirects is disable
>
> And there is my code:
>
> <?xml version="1.0" encoding="ISO-8859-1" ?>
> <!--PruebaPc000.xml
> flujo que reproduce los siguientes casos-->
>
> <!DOCTYPE project SYSTEM "WebTest.dtd"[
> <!ENTITY config SYSTEM "config.xml">
> <!ENTITY login SYSTEM "file:modules/login.xml">
> <!ENTITY RCC SYSTEM "file:modules/RCC.xml">
> <!ENTITY tareas SYSTEM "file:modules/Tareas.xml">
> <!ENTITY avisos SYSTEM "file:modules/Avisos.xml">
> <!ENTITY apertura SYSTEM "file:modules/Apertura.xml">
> <!ENTITY aperturaCaso SYSTEM "file:modules/AperturaCaso.xml">
> <!ENTITY archivador SYSTEM "file:modules/Archivador.xml">
> <!ENTITY estadisticas SYSTEM "file:modules/Estadisticas.xml">
> <!ENTITY mantenimientos SYSTEM "file:modules/Mantenimientos.xml">
> <!ENTITY dependencia SYSTEM "file:modules/Dependencia.xml">
> <!ENTITY historicos SYSTEM "file:modules/Historicos.xml">
> <!ENTITY rSociales SYSTEM "file:modules/RecursosSociales.xml">
> <!ENTITY dApertura SYSTEM "file:modules/DatosApertura000.xml">
>
> ]>
>
> <project name="SAUSS" basedir="." default="main">
>
> <property name="webtest.home" location="C:/webtest" />
> <property name="contentType" value="" />
> <import file="${webtest.home}/lib/taskdef.xml"/>
> <!--USUARIO login-->
> <property name="USUARIO" value="MARIA" />
> <!--DATOS APERTURA-->
> <property name="nombre" value="astro" />
> <property name="apellidos" value="0" />
>
>
> <target name="main">
> <webtest name="PruebaPc000">
>
> <!--Archivo de configuracion-->
> <config description="respuesta del host, reporting and logging"
> host="espinete" port="7783" protocol="http" basepath=""
> autorefresh="true"
> summary="true" saveresponse="true" saveprefix="PruebaPc000"
> resultpath="${webtest.home}/SAUSS/results" resultfile="resultados.xml"
>
> >
>
> <header name="User-Agent" value="MSIE 6.0b" />
> <header name="Connection" value="Keep-Alive"/>
> <header name="Cache-Control" value="no-cache"/>
>
> </config>
> <steps>
> <enableJavaScript description="Se habilita la ejecucion de
> scripts java"
> enable="true" />
> &login;
> &RCC;
> &apertura;
> &aperturaCaso;
>
> <!--DatosApertura000-->
> <setInputField description="set user NOMBRE=
> ${nombre}"
> name="nombre" value="${nombre}" />
> <setInputField description="set user APELLIDOS=
> ${apellidos}"
> name="apellidos" value="${apellidos}" />
> <setCheckbox description="Sin limite resultados"
> name="sinLimiteResultados" value="S"/>
> <verifyCheckbox description="Sin limite resultados"
> name="sinLimiteResultados" checked="true" />
> <clickButton description="Click the submit button
> 5: botonBuscar"
> name="botonBuscar" />
>
>
>
> <!--NO COINCIDENCIA HISTORIA SOCIAL-->
> <!--NO habia una HS anterior creada: Apertura de Nueva
> Historia Social-->
> <verifyText description="Texto presente 2:
> Nueva historia social"
> text=" Nueva historia social" />
> <verifyText description="Texto presente 2: No se
> ha encontrado"
> text="No se ha encontrado" />
> <verifyText description="Texto presente 2: Pulse
> 'Aceptar' si desea proceder a dar de alta una Historia Social asociada a
> este nuevo Titular"
> text="Pulse 'Aceptar' si desea proceder a dar de
> alta una Historia Social asociada a este nuevo Titular" />
> <clickButton description="Click the submit button
> 6: botonAceptar"
> name="botonAceptar" />
>
>
> <verifyText description="Texto presente 1:
> Introduzca los datos del Titular de la H.S. que desea crear"
> text="Introduzca los datos del Titular de la H.S.
> que desea crear" />
>
> <!--Deberia pasar estos 2 pasos y fallar en el anterior-->
> <verifyText description="Texto presente 3:
> Cabecera de la historia social"
> text="Cabecera de la historia social" />
>
> <verifyText description="Texto presente: Datos
> generales"
> text="Datos generales" />
>
>
> </steps>
> </webtest>
> </target>
> </project>
>
>
> Do you have any idea about what happens?
>
> Thanks.
>
>
> Francisco Javier Martín
>
>
> AVISO LEGAL: La informacion contenida en este mensaje y cualquier documento adjunto en el mismo es confidencial, puede estar legalmente protegida y esta dirigida solamente al destinatario. La publicacion, uso, distribucion, impresion o copia no autorizada del contenido de este mensaje, esta estrictamente prohibida y puede ser ilegal. Si Vd. ha recibido este mensaje 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 document is confidential, covered by law and intended solely for the recipient. 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.
>
> _______________________________________________
> WebTest mailing list
> WebTest@lists.canoo.com
> http://lists.canoo.com/mailman/listinfo/webtest
>