[Webtest] Previousresponse Question

Dierk Koenig webtest@lists.canoo.com
Fri, 22 Aug 2003 13:40:43 +0200


This is a multi-part message in MIME format.

------=_NextPart_000_000D_01C368B2.FBA55650
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit

Hi Saba,

using <previousresponse/> can be quite confusing as the behaviour may differ
from what you see in the browser.
(cf. http://webtest.canoo.com/webtest/manual/syntax.html#21)

Is any JavaScript in play?

I would add a step "6.a" that verifies that you are back on the page you
expected.
This may give further indications.

As a workaround you can also omit the <previousresponse/> altogether by
replacing step 6 with step 2.

cheers
Mittie

BTW: is it expected that the user may use the back button to go back to a
page that he left with "cancel"?
  -----Original Message-----
  From: webtest-admin@lists.canoo.com
[mailto:webtest-admin@lists.canoo.com]On Behalf Of Saba Sundke
  Sent: Freitag, 22. August 2003 12:53
  To: Webtest
  Subject: [Webtest] Previousresponse Question


  Hi

  In my application there a main page, a search page and a search results
page. When I click on the 'Search' link on the main page, I go to the search
page. The search page has 2 buttons. The 'Search' Button will lead to the
Search Results page and the 'Cancel' button will go back to the main page.

  My Test Case has the following steps
  1. Go to Main Page
  2. Click on 'Search' Link (Go to search page)
  3. Verify that the criteria text box is at the default value
  4. Click on 'Cancel' (Back to main page)
  5. Verify title on main page
  6. Get previous response (Search page)
  7. Set Search criteria
  8. Hit 'Search' button (Got to the Search Results page)
  9. Verify Search results

  Now is the usage of previous response at step 6 correct i.e will I get the
Search page back?. When using it this way, the results are weird.
  1. If the above steps are executed, the search results step 9 fails. The
response that it got for that step is the main page (and hence it fails) How
come it does not get the search results page?
  2. If I remove steps 4, 5, 6 and do a normal operation (w/o Cancel) I get
the Search results
  3. If I just remove step 6; keeping 4, 5 intact (which means that I'm on
the main page after Cancel), surprisingly step 7 passes (setting search
criteria) and step 8 fails saying there is no 'Search' button on the page.
Step 8 failing is okay; how did step 7 pass?

  I'm confused. Please advice

  - Saba







------=_NextPart_000_000D_01C368B2.FBA55650
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=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2730.1700" name=3DGENERATOR></HEAD>
<BODY>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =
size=3D2>Hi=20
Saba,</FONT></SPAN></DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =
size=3D2>using=20
&lt;previousresponse/&gt; can be quite confusing as the behaviour may =
differ=20
from what you see in the browser.</FONT></SPAN></DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =
size=3D2>(cf.=20
<A=20
href=3D"http://webtest.canoo.com/webtest/manual/syntax.html#21">http://we=
btest.canoo.com/webtest/manual/syntax.html#21</A>)</FONT></SPAN></DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =
size=3D2>Is any=20
JavaScript in play?</FONT></SPAN></DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =
size=3D2>I=20
would add a step "6.a" that verifies that you are back on the page you=20
expected.</FONT></SPAN></DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =
size=3D2>This=20
may give further indications.</FONT></SPAN></DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =
size=3D2>As a=20
workaround you can also omit the &lt;previousresponse/&gt; altogether by =

replacing step 6 with step 2.</FONT></SPAN></DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =

size=3D2>cheers</FONT></SPAN></DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =

size=3D2>Mittie</FONT></SPAN></DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D686122911-22082003><FONT face=3DArial color=3D#0000ff =
size=3D2>BTW:=20
is it expected that the user may use the back button to go back to a =
page that=20
he left with "cancel"?</FONT></SPAN></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #0000ff 2px =
solid; MARGIN-RIGHT: 0px">
  <DIV class=3DOutlookMessageHeader dir=3Dltr align=3Dleft><FONT =
face=3DTahoma=20
  size=3D2>-----Original Message-----<BR><B>From:</B>=20
  webtest-admin@lists.canoo.com =
[mailto:webtest-admin@lists.canoo.com]<B>On=20
  Behalf Of </B>Saba Sundke<BR><B>Sent:</B> Freitag, 22. August 2003=20
  12:53<BR><B>To:</B> Webtest<BR><B>Subject:</B> [Webtest] =
Previousresponse=20
  Question<BR><BR></FONT></DIV>
  <DIV><SPAN class=3D718293208-22082003>Hi </SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D718293208-22082003>In my application there a main =
page, a=20
  search page and a search results page. When I click on&nbsp;the=20
  'Search'&nbsp;link on the main page, I go to the search page. The =
search page=20
  has 2 buttons. The 'Search' Button will lead to the Search Results =
page and=20
  the 'Cancel' button will go back to the main page.</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D718293208-22082003>My Test Case has the following=20
  steps</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>1. Go to Main Page</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>2. Click on 'Search' Link (Go to =
search=20
  page)</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>3. Verify that the criteria text =
box is at=20
  the default value</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>4. Click on 'Cancel' (Back to =
main=20
  page)</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>5. Verify title on main =
page</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>6. Get previous response (Search =

  page)</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>7. Set Search =
criteria</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>8. Hit 'Search' button (Got to =
the Search=20
  Results page)</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>9. Verify Search =
results</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D718293208-22082003>Now is the usage of previous =
response at=20
  step&nbsp;6 correct i.e will I get the Search page back?. When using =
it this=20
  way, the results are weird.</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>1. If the above steps are =
executed, the=20
  search results step 9 fails. The response that it got for that step is =
the=20
  main page (and hence it fails) How come it does not get the search =
results=20
  page?</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>2. If I remove steps 4, 5, 6 and =
do a=20
  normal operation (w/o Cancel) I get the Search results</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003>3. If I just remove step 6; =
keeping 4, 5=20
  intact (which means that I'm on the main page after Cancel), =
surprisingly step=20
  7 passes (setting search criteria) and step 8 fails saying there is no =

  'Search' button on the page. Step 8 failing is okay; how did step 7=20
  pass?</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D718293208-22082003>I'm confused. Please =
advice</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D718293208-22082003>- Saba</SPAN></DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D718293208-22082003></SPAN>&nbsp;</DIV>
  <DIV><SPAN=20
class=3D718293208-22082003></SPAN>&nbsp;</DIV></BLOCKQUOTE></BODY></HTML>=


------=_NextPart_000_000D_01C368B2.FBA55650--