[Webtest] Login Problem

Ian Phillips Ian Phillips" <phillipsic@gmail.com
Wed, 2 May 2007 10:38:54 +0200


------=_Part_2631_2550976.1178095134625
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

Hi Marc.

I have investigated cookies a bit more (I disabled all cookies and found I
could not log in).  So hopefully I have found my answer.  The developer
appears not to know his own application as I was told by him that cookies
were not used.

Thanks for the help.

Ian

On 4/30/07, Marc Guillemot <mguillemot@yahoo.fr> wrote:
>
> and could you "see" (with the application log for instance) why the
> application decides to refuse login?
>
> Marc.
>
> Ian Phillips wrote:
> > Hi Marc.
> >
> > I have monitored the http conversation and the correct information does
> > appear to be sent.  I have been told by the developer that cookies are
> > not used.
> >
> > Thanks.
> >
> > Ian
> >
> >
> > On 4/30/07, *Marc Guillemot* <mguillemot@yahoo.fr
> > <mailto:mguillemot@yahoo.fr>> wrote:
> >
> >     Hi Ian,
> >
> >     have you tried to monitor the http conversation? Do you use cookies?
> May
> >     it be due to a cookie format problem?
> >
> >     Marc.
> >
> >     Ian Phillips wrote:
> >     > Hi.
> >     >
> >     > I am having a problem getting webtest to login.  It appears not to
> >     > accept the username and/or password.
> >     >
> >     > My login page looks like this:
> >     >
> >     > FORM METHOD=post
> >     > ACTION
> >     > ="index.php">
> >     > <table align=center>
> >     >       <
> >     > tr><th>Name: <td><INPUT
> >     >  SIZE=10
> >     > NAME="login">
> >     >       <tr><th>Password:<
> >     > td> <INPUT SIZE
> >     > =10 TYPE="password"
> >     > NAME="passwd">
> >     >       <tr><td colspan
> >     > =2 align
> >     > =center>
> >     >
> >     >       <INPUT
> >     >  TYPE="hidden" NAME="what" VALUE=
> >     > "loggon_step"
> >     >>
> >     >       <INPUT TYPE="hidden" NAME=
> >     > "myGroup" VALUE="-1">
> >     >       <INPUT
> >     >  TYPE=
> >     > "submit" VALUE=" Login ">
> >     > </table>
> >     > </FORM>
> >     >
> >     > My script looks like this:
> >     >
> >     > <project name="SimpleTest" basedir="." default="main">
> >     >
> >     >   <property name="webtest.home " location="C:\canoo" />
> >     >   <import file="${webtest.home}/lib/taskdef.xml"/>
> >     >
> >     >   <target name="main">
> >     >     <webtest name="myTest">
> >     >       <config
> >     >         host="wokingham"
> >     >         port="29920"
> >     >         protocol="http"
> >     >         basepath=""
> >     >         summary="true"
> >     >         saveresponse="true"
> >     >         autorefresh="true"/>
> >     >
> >     >       <steps>
> >     >         <invoke
> >     >           description="get Login Page"
> >     >           url="" />
> >     >         <verifyTitle
> >     >           description="we should see the login title"
> >     >           text="KPSA" />
> >     >         <setInputField description="set user name"
> >     >           name="login"
> >     >           value="KOPAdmin" />
> >     >         <setInputField description="set password"
> >     >           name="passwd"
> >     >           value="*****" />
> >     >         <clickButton
> >     >           label=" Login "
> >     >           description="Login" />
> >     >         <verifyTitle
> >     >           description="we should see the Admin title"
> >     >           text="KPSA Administration" />
> >     >       </steps>
> >     >     </webtest>
> >     >   </target>
> >     > </project>
> >     >
> >     > I can manually login so I know the username/password are OK.  When
> >     I run
> >     > the test above I get a page saying the login has failed.  None of
> the
> >     > steps appear to fail until I try to validate the title of the
> >     admin page.
> >     >
> >     > Thanks for any help.
> >     >
> >     > Ian
> >     >
> >     >
> >
> >     _______________________________________________
> >     WebTest mailing list
> >     WebTest@lists.canoo.com <mailto:WebTest@lists.canoo.com>
> >     http://lists.canoo.com/mailman/listinfo/webtest
> >
> >
>
> _______________________________________________
> WebTest mailing list
> WebTest@lists.canoo.com
> http://lists.canoo.com/mailman/listinfo/webtest
>

------=_Part_2631_2550976.1178095134625
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

Hi Marc.<br><br>I have investigated cookies a bit more (I disabled all cookies and found I could not log in).&nbsp; So hopefully I have found my answer.&nbsp; The developer appears not to know his own application as I was told by him that cookies were not used.
<br><br>Thanks for the help.<br><br>Ian<br><br><div><span class="gmail_quote">On 4/30/07, <b class="gmail_sendername">Marc Guillemot</b> &lt;<a href="mailto:mguillemot@yahoo.fr">mguillemot@yahoo.fr</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
and could you &quot;see&quot; (with the application log for instance) why the<br>application decides to refuse login?<br><br>Marc.<br><br>Ian Phillips wrote:<br>&gt; Hi Marc.<br>&gt;<br>&gt; I have monitored the http conversation and the correct information does
<br>&gt; appear to be sent.&nbsp;&nbsp;I have been told by the developer that cookies are<br>&gt; not used.<br>&gt;<br>&gt; Thanks.<br>&gt;<br>&gt; Ian<br>&gt;<br>&gt;<br>&gt; On 4/30/07, *Marc Guillemot* &lt;<a href="mailto:mguillemot@yahoo.fr">
mguillemot@yahoo.fr</a><br>&gt; &lt;mailto:<a href="mailto:mguillemot@yahoo.fr">mguillemot@yahoo.fr</a>&gt;&gt; wrote:<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Hi Ian,<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; have you tried to monitor the http conversation? Do you use cookies? May
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; it be due to a cookie format problem?<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Marc.<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Ian Phillips wrote:<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; Hi.<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; I am having a problem getting webtest to login.&nbsp;&nbsp;It appears not to
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; accept the username and/or password.<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; My login page looks like this:<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; FORM METHOD=post<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; ACTION<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; =&quot;index.php
&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; &lt;table align=center&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; tr&gt;&lt;th&gt;Name: &lt;td&gt;&lt;INPUT<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;SIZE=10<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; NAME=&quot;login&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;tr&gt;&lt;th&gt;Password:&lt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; td&gt; &lt;INPUT SIZE<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; =10 TYPE=&quot;password&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; NAME=&quot;passwd&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;tr&gt;&lt;td colspan<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; =2 align<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; =center&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;INPUT<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;TYPE=&quot;hidden&quot; NAME=&quot;what&quot; VALUE=<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; &quot;loggon_step&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;INPUT TYPE=&quot;hidden&quot; NAME=
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; &quot;myGroup&quot; VALUE=&quot;-1&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;INPUT<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;TYPE=<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; &quot;submit&quot; VALUE=&quot; Login &quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; &lt;/table&gt;<br>
&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; &lt;/FORM&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; My script looks like this:<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; &lt;project name=&quot;SimpleTest&quot; basedir=&quot;.&quot; default=&quot;main&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; &lt;property name=&quot;webtest.home &quot; location=&quot;C:\canoo&quot; /&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; &lt;import file=&quot;${webtest.home}/lib/taskdef.xml&quot;/&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; &lt;target name=&quot;main&quot;&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp; &lt;webtest name=&quot;myTest&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;config<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; host=&quot;wokingham&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; port=&quot;29920&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; protocol=&quot;http&quot;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; basepath=&quot;&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; summary=&quot;true&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; saveresponse=&quot;true&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; autorefresh=&quot;true&quot;/&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;steps&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;invoke<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; description=&quot;get Login Page&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; url=&quot;&quot; /&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;verifyTitle
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; description=&quot;we should see the login title&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; text=&quot;KPSA&quot; /&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;setInputField description=&quot;set user name&quot;<br>
&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; name=&quot;login&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; value=&quot;KOPAdmin&quot; /&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;setInputField description=&quot;set password&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; name=&quot;passwd&quot;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; value=&quot;*****&quot; /&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;clickButton<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; label=&quot; Login &quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; description=&quot;Login&quot; /&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;verifyTitle
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; description=&quot;we should see the Admin title&quot;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; text=&quot;KPSA Administration&quot; /&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/steps&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/webtest&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;&nbsp;&nbsp; &lt;/target&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; &lt;/project&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; I can manually login so I know the username/password are OK.&nbsp;&nbsp;When<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; I run<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; the test above I get a page saying the login has failed.&nbsp;&nbsp;None of the
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; steps appear to fail until I try to validate the title of the<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; admin page.<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; Thanks for any help.<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt; Ian<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &gt;
<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; _______________________________________________<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; WebTest mailing list<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; <a href="mailto:WebTest@lists.canoo.com">WebTest@lists.canoo.com</a> &lt;mailto:<a href="mailto:WebTest@lists.canoo.com">
WebTest@lists.canoo.com</a>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; <a href="http://lists.canoo.com/mailman/listinfo/webtest">http://lists.canoo.com/mailman/listinfo/webtest</a><br>&gt;<br>&gt;<br><br>_______________________________________________
<br>WebTest mailing list<br><a href="mailto:WebTest@lists.canoo.com">WebTest@lists.canoo.com</a><br><a href="http://lists.canoo.com/mailman/listinfo/webtest">http://lists.canoo.com/mailman/listinfo/webtest</a><br></blockquote>
</div><br>

------=_Part_2631_2550976.1178095134625--