[Webtest] clickbutton doesnt work

Brandon Moore webtest@lists.canoo.com
Thu, 17 Jul 2003 14:18:21 -0500


This is a multi-part message in MIME format.

------=_NextPart_000_000C_01C34C6E.50686BC0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit

buttons need to be inside a form.
what did you expect the button to do?
webtest is much happier with valid html.
I had trouble with a META tag before the HTML tag, which hid the title
(error correcting parser, long story)

-----Original Message-----
From: webtest-admin@lists.canoo.com [mailto:webtest-admin@lists.canoo.com]On
Behalf Of Allan Murphy
Sent: Thursday, July 17, 2003 2:15 PM
To: webtest@lists.canoo.com
Subject: [Webtest] clickbutton doesnt work

Hi, Im new to CanooWT and i think it would be awesome if it really worked :(
because i have tried several days to get one single example working and
nothing.
 it seems that it cant find buttons, i check the output page and its ok, but
the test i built doesnt run.
 HELP!

 html code:test.htm
----------------------
<html>
<head>
<title>no title</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0"
marginwidth="0" marginheight="0">
   <button type="submit" name="1" />
</body>
</html>
----------------------------
xml code: test.xml
<project name="SimpleTest" basedir="." default="main">
  <property name="webtest.home" value="d:\webtest"/>
   <taskdef file="${webtest.home}/webtestTaskdefs.properties">
      <classpath>
         <fileset dir="${webtest.home}" includes="**/lib/*.jar"/>
      </classpath>
   </taskdef>
   <target name="main">
      <testSpec name="myTest">
         <config
            host="localhost"
            port="80"
            protocol="http"
            basepath=""
            showhtmlparseroutput="true"
            saveresponse="true"
            resultpath="/tmp/results" />
         <steps>
            <invoke stepid="get Login Page" url="test.htm />


            <clickbutton stepid="Submit the simple form" name="1" />
         </steps>
      </testSpec>
   </target>
</project>
---------------------------------
when i run this i get:
D:\>ant -buildfile test.xml
Buildfile: test.xml
main:
BUILD FAILED
Test step clickbutton named "Submit the simple form" failed with message
"Button with name <1> and value <<not specified>> not found!"
Total time: 3 seconds

please help!!!!!
Thanks.
Allan Murphy M.
Informatics Eng.
Chile




  _____

MSN 8 with e-mail virus protection service: 2 months FREE*
_______________________________________________ WebTest mailing list
WebTest@lists.canoo.com http://lists.canoo.com/mailman/listinfo/webtest


------=_NextPart_000_000C_01C34C6E.50686BC0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">


<META content=3D"MSHTML 6.00.2800.1141" name=3DGENERATOR></HEAD>
<BODY>
<DIV><SPAN class=3D756431219-17072003><FONT face=3DArial color=3D#0000ff =

size=3D2>buttons need to be inside a form.</FONT></SPAN></DIV>
<DIV><SPAN class=3D756431219-17072003><FONT face=3DArial color=3D#0000ff =
size=3D2>what=20
did you expect the button to do?</FONT></SPAN></DIV>
<DIV><SPAN class=3D756431219-17072003><FONT face=3DArial color=3D#0000ff =

size=3D2>webtest is much happier with valid html.</FONT></SPAN></DIV>
<DIV><SPAN class=3D756431219-17072003><FONT face=3DArial color=3D#0000ff =
size=3D2>I had=20
trouble with a META tag before the HTML tag, which hid the=20
title</FONT></SPAN></DIV>
<DIV><SPAN class=3D756431219-17072003><FONT face=3DArial color=3D#0000ff =
size=3D2>(error=20
correcting parser, long story)</FONT></SPAN></DIV>
<DIV><FONT face=3DTahoma><FONT face=3DArial><FONT color=3D#0000ff><FONT =
size=3D2><SPAN=20
class=3D756431219-17072003></SPAN></FONT></FONT></FONT><FONT =
face=3DArial=20
color=3D#0000ff size=3D2></FONT><BR><FONT size=3D2>-----Original=20
Message-----<BR><B>From:</B> webtest-admin@lists.canoo.com=20
[mailto:webtest-admin@lists.canoo.com]<B>On Behalf Of </B>Allan=20
Murphy<BR><B>Sent:</B> Thursday, July 17, 2003 2:15 PM<BR><B>To:</B>=20
webtest@lists.canoo.com<BR><B>Subject:</B> [Webtest] clickbutton doesnt=20
work<BR></FONT></FONT><BR>Hi, Im new to CanooWT and i think it would be =
awesome=20
if it really worked :(<BR>because i have tried several days to get one =
single=20
example working and nothing.<BR><SPAN class=3D756431219-17072003><FONT =
face=3DArial=20
color=3D#0000ff size=3D2>&nbsp;</FONT></SPAN>it seems that it cant find =
buttons, i=20
check the output page and its ok, but the test i built doesnt =
run.<BR><SPAN=20
class=3D756431219-17072003><FONT face=3DArial color=3D#0000ff=20
size=3D2>&nbsp;</FONT></SPAN>HELP!<BR><BR><FONT face=3DArial><FONT=20
color=3D#0000ff><FONT size=3D2><SPAN =
class=3D756431219-17072003>&nbsp;</SPAN>html=20
code:test.htm</FONT></FONT></FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff =
size=3D2>----------------------</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff=20
size=3D2>&lt;html&gt;<BR>&lt;head&gt;<BR>&lt;title&gt;no=20
title&lt;/title&gt;<BR>&lt;meta http-equiv=3D"Content-Type" =
content=3D"text/html;=20
charset=3Diso-8859-1"&gt;<BR>&lt;/head&gt;<BR>&lt;body =
bgcolor=3D"#FFFFFF"=20
text=3D"#000000" leftmargin=3D"0" topmargin=3D"0" marginwidth=3D"0"=20
marginheight=3D"0"&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>&nbsp;&nbsp; &lt;button =
type=3D"submit"=20
name=3D"1" /&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff=20
size=3D2>&lt;/body&gt;<BR>&lt;/html&gt;<BR>----------------------------</=
FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>xml code: =
test.xml</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>&lt;project =
name=3D"SimpleTest"=20
basedir=3D"." default=3D"main"&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>&nbsp; &lt;property=20
name=3D"webtest.home" value=3D"d:\webtest"/&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>&nbsp;&nbsp; =
&lt;taskdef=20
file=3D"${webtest.home}/webtestTaskdefs.properties"&gt;<BR>&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;=20
&lt;classpath&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
&lt;fileset dir=3D"${webtest.home}"=20
includes=3D"**/lib/*.jar"/&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
&lt;/classpath&gt;<BR>&nbsp;&nbsp; &lt;/taskdef&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>&nbsp;&nbsp; &lt;target =

name=3D"main"&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff =
size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
&lt;testSpec name=3D"myTest"&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff=20
size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
&lt;config<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp=
;&nbsp;=20
host=3D"localhost"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp;=20
port=3D"80"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;&nbsp;=20
protocol=3D"http"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;&nbsp;&nbsp;=20
basepath=3D""<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;=20
showhtmlparseroutput=3D"true"=20
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
saveresponse=3D"true"=20
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
resultpath=3D"/tmp/results" /&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff=20
size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
&lt;steps&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff=20
size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;=20
&lt;invoke stepid=3D"get Login Page" url=3D"test.htm=20
/&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;=20
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
&lt;clickbutton stepid=3D"Submit the simple form" name=3D"1" =
/&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff=20
size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
&lt;/steps&gt;</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff =
size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
&lt;/testSpec&gt;<BR>&nbsp;&nbsp;=20
&lt;/target&gt;<BR>&lt;/project&gt;<BR>---------------------------------<=
/FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>when i run this i =
get:</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>D:\&gt;ant -buildfile=20
test.xml<BR>Buildfile: test.xml</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>main:</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>BUILD FAILED<BR>Test =
step clickbutton=20
named "Submit the simple form" failed with message "Button&nbsp;with =
name=20
&lt;1&gt; and value &lt;&lt;not specified&gt;&gt; not =
found!"</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>Total time: 3 =
seconds</FONT></DIV>
<DIV></DIV>
<DIV>&nbsp;</DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>please =
help!!!!!</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2>Thanks.</FONT></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial><FONT size=3D2><FONT =
color=3D#0000ff><STRONG>Allan Murphy=20
M.</STRONG><BR>Informatics Eng.<BR>Chile</FONT></FONT></FONT></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><BR =
clear=3Dall></FONT>&nbsp;</DIV>
<BLOCKQUOTE>
  <DIV><FONT face=3DArial color=3D#0000ff size=3D2>
  <HR>
  MSN 8 with </FONT><A =
href=3D"http://g.msn.com/8HMBEN/2740??PS=3D"><FONT face=3DArial=20
  size=3D2>e-mail virus protection service: </FONT></A><FONT =
face=3DArial=20
  color=3D#0000ff size=3D2>2 months FREE*=20
  _______________________________________________ WebTest mailing list=20
  WebTest@lists.canoo.com=20
  =
http://lists.canoo.com/mailman/listinfo/webtest</FONT></DIV></BLOCKQUOTE>=
</BODY></HTML>

------=_NextPart_000_000C_01C34C6E.50686BC0--