[Webtest] [Webtest How to Follow javascript menus]

Bianchini, William L. webtest@lists.canoo.com
Thu, 26 Aug 2004 20:38:19 -0500


This is a multi-part message in MIME format.

------_=_NextPart_001_01C48BD6.884673BB
Content-Type: text/plain;
	charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Hi all,

=20

I'm sure somebody has been through this before and I am just missing
some key concept so if anyone can please steer me in the proper
direction I would sure appreciate it.

I need to figure out how I navigate to pages that are referred to by
links in javascript, in a struts app, without doing a new invoke step.
The links aren't an href in an anchor tag or a html form with a submit
button on the page they are in javascript generated menus and called by
a javascript that catches an onClick event or something.  When I use an
invoke step to refer to the url pointed to by the javascript menu it
blows away some session variables and then is trapped by the
applications security, which reroutes me...I'm sure you get the picture.
Disabling the session security and letting the session variables get
blown away, kind of spoils the test too.

=20

What I want to do is something like this.  In one session.

1. Invoke main page.

2. Populate login form.

3. Submit login from.

4. Confirm successful login.

5. Go to some link that is normally called with a javascript and is not
a regular html tag.

And I can do 1-4 of these steps  but then I want to (5) Follow some link
that is javascript generated without starting a new session as well.

=20

Thanks,

Trey

=20

=20

=20


------_=_NextPart_001_01C48BD6.884673BB
Content-Type: text/html;
	charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<html xmlns:v=3D"urn:schemas-microsoft-com:vml" =
xmlns:o=3D"urn:schemas-microsoft-com:office:office" =
xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns=3D"http://www.w3.org/TR/REC-html40">

<head>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Dus-ascii">
<meta name=3DGenerator content=3D"Microsoft Word 11 (filtered medium)">
<style>
<!--
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	margin-bottom:.0001pt;
	font-size:12.0pt;
	font-family:"Times New Roman";}
h1
	{margin-top:12.0pt;
	margin-right:0in;
	margin-bottom:3.0pt;
	margin-left:0in;
	font-size:16.0pt;
	font-family:Arial;}
a:link, span.MsoHyperlink
	{color:blue;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{color:purple;
	text-decoration:underline;}
pre
	{margin:0in;
	margin-bottom:.0001pt;
	font-size:10.0pt;
	font-family:"Courier New";}
p.pageheading1, li.pageheading1, div.pageheading1
	{margin-top:24.0pt;
	margin-right:0in;
	margin-bottom:24.0pt;
	margin-left:0in;
	text-indent:0in;
	mso-list:l1 level1 lfo2;
	font-size:28.0pt;
	font-family:Arial;
	font-variant:small-caps;
	letter-spacing:4.0pt;
	font-weight:bold;}
p.pageheading10, li.pageheading10, div.pageheading10
	{margin-top:24.0pt;
	margin-right:0in;
	margin-bottom:24.0pt;
	margin-left:0in;
	text-indent:0in;
	mso-list:l1 level1 lfo3;
	font-size:28.0pt;
	font-family:Arial;
	font-variant:small-caps;
	letter-spacing:4.0pt;
	font-weight:bold;}
p.pageheading100, li.pageheading100, div.pageheading100
	{margin-top:24.0pt;
	margin-right:0in;
	margin-bottom:24.0pt;
	margin-left:0in;
	text-indent:0in;
	mso-list:l0 level1 lfo5;
	font-size:28.0pt;
	font-family:Arial;
	font-variant:small-caps;
	letter-spacing:4.0pt;
	font-weight:bold;}
p.pageheading1000, li.pageheading1000, div.pageheading1000
	{margin-top:24.0pt;
	margin-right:0in;
	margin-bottom:24.0pt;
	margin-left:0in;
	text-indent:0in;
	mso-list:l0 level1 lfo6;
	font-size:28.0pt;
	font-family:Arial;
	font-variant:small-caps;
	letter-spacing:4.0pt;
	font-weight:bold;}
p.pageheading10000, li.pageheading10000, div.pageheading10000
	{margin-top:24.0pt;
	margin-right:0in;
	margin-bottom:24.0pt;
	margin-left:0in;
	text-indent:0in;
	mso-list:l0 level1 lfo7;
	font-size:28.0pt;
	font-family:Arial;
	font-variant:small-caps;
	letter-spacing:4.0pt;
	font-weight:bold;}
p.pageheading100000, li.pageheading100000, div.pageheading100000
	{margin-top:24.0pt;
	margin-right:0in;
	margin-bottom:24.0pt;
	margin-left:0in;
	text-indent:0in;
	mso-list:l2 level1 lfo9;
	font-size:28.0pt;
	font-family:Arial;
	font-variant:small-caps;
	letter-spacing:4.0pt;
	font-weight:bold;}
p.pageheading1000000, li.pageheading1000000, div.pageheading1000000
	{margin-top:24.0pt;
	margin-right:0in;
	margin-bottom:24.0pt;
	margin-left:0in;
	text-indent:0in;
	mso-list:l2 level1 lfo10;
	font-size:28.0pt;
	font-family:Arial;
	font-variant:small-caps;
	letter-spacing:4.0pt;
	font-weight:bold;}
span.EmailStyle25
	{mso-style-type:personal;
	font-family:Arial;
	color:windowtext;}
span.EmailStyle26
	{mso-style-type:personal;
	font-family:Arial;
	color:navy;}
span.EmailStyle27
	{mso-style-type:personal;
	font-family:Arial;
	color:navy;}
span.EmailStyle28
	{mso-style-type:personal;
	font-family:Arial;
	color:navy;}
span.EmailStyle29
	{mso-style-type:personal;
	font-family:Arial;
	color:navy;}
span.EmailStyle30
	{mso-style-type:personal;
	font-family:Arial;
	color:navy;}
span.EmailStyle31
	{mso-style-type:personal;
	font-family:Arial;
	color:navy;}
span.EmailStyle32
	{mso-style-type:personal;
	font-family:Arial;
	color:navy;}
span.EmailStyle33
	{mso-style-type:personal-reply;
	font-family:Arial;
	color:navy;}
@page Section1
	{size:8.5in 11.0in;
	margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
	{page:Section1;}
 /* List Definitions */
 @list l0
	{mso-list-id:240256271;
	mso-list-template-ids:-1615041978;}
@list l0:level1
	{mso-level-tab-stop:.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l0:level2
	{mso-level-tab-stop:1.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l0:level3
	{mso-level-tab-stop:1.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l0:level4
	{mso-level-tab-stop:2.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l0:level5
	{mso-level-tab-stop:2.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l0:level6
	{mso-level-tab-stop:3.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l0:level7
	{mso-level-tab-stop:3.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l0:level8
	{mso-level-tab-stop:4.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l0:level9
	{mso-level-tab-stop:4.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1
	{mso-list-id:595594193;
	mso-list-template-ids:-697680116;}
@list l1:level1
	{mso-level-tab-stop:.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1:level2
	{mso-level-tab-stop:1.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1:level3
	{mso-level-tab-stop:1.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1:level4
	{mso-level-tab-stop:2.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1:level5
	{mso-level-tab-stop:2.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1:level6
	{mso-level-tab-stop:3.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1:level7
	{mso-level-tab-stop:3.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1:level8
	{mso-level-tab-stop:4.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1:level9
	{mso-level-tab-stop:4.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l2
	{mso-list-id:1283727503;
	mso-list-template-ids:-1855158714;}
@list l2:level1
	{mso-level-tab-stop:.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l2:level2
	{mso-level-tab-stop:1.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l2:level3
	{mso-level-tab-stop:1.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l2:level4
	{mso-level-tab-stop:2.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l2:level5
	{mso-level-tab-stop:2.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l2:level6
	{mso-level-tab-stop:3.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l2:level7
	{mso-level-tab-stop:3.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l2:level8
	{mso-level-tab-stop:4.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l2:level9
	{mso-level-tab-stop:4.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
ol
	{margin-bottom:0in;}
ul
	{margin-bottom:0in;}
-->
</style>
<!--[if gte mso 9]><xml>
 <o:shapedefaults v:ext=3D"edit" spidmax=3D"1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
 <o:shapelayout v:ext=3D"edit">
  <o:idmap v:ext=3D"edit" data=3D"1" />
 </o:shapelayout></xml><![endif]-->
</head>

<body lang=3DEN-US link=3Dblue vlink=3Dpurple>

<div class=3DSection1>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>Hi =
all,<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier =
New"'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>I'm sure somebody =
has been
through this before and I am just missing some key concept so if anyone =
can
please steer me in the proper direction I would sure appreciate =
it.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>I need to figure =
out how I
navigate to pages that are referred to by links in javascript, in a =
struts app,
without doing a new invoke step.&nbsp; The links aren't an href in an =
anchor tag or
a html form with a submit button on the page they are in javascript =
generated
menus and called by a javascript that catches an onClick event or =
something.&nbsp;
When I use an invoke step to refer to the url pointed to by the =
javascript menu
it blows away some session variables and then is trapped by the =
applications
security, which reroutes me...I'm sure you get the picture.&nbsp; =
Disabling the
session security and letting the session variables get blown away, kind =
of
spoils the test too.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier =
New"'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>What I want to do =
is
something like this. &nbsp;In one session.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>1. Invoke main =
page.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>2. Populate login =
form.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>3. Submit login =
from.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>4. Confirm =
successful login.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>5. Go to some link =
that is
normally called with a javascript and is not a regular html =
tag.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>And I can do 1-4 of =
these
steps&nbsp; but then I want to (5) Follow some link that is javascript =
generated
without starting a new session as well.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier =
New"'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier =
New"'>Thanks,<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier =
New"'>Trey<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier =
New"'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-autospace:none'><font size=3D2 =
face=3D"Courier New"><span
style=3D'font-size:10.0pt;font-family:"Courier =
New"'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

</div>

</body>

</html>

------_=_NextPart_001_01C48BD6.884673BB--