Re[1]: [Webtest] JavaScript support (again)

Lisa Crispin webtest@lists.canoo.com
Fri, 19 Nov 2004 22:28:19 +0000


--NextPart_Webmail_9m3u9jl4l_14731_1100903299_0
Content-Type: text/plain
Content-Transfer-Encoding: 8bit

Hi Costin,
I am just using the regular WebTest syntax, I'm afraid I don't really understand your question.  For example, I did a test where I used clicklink to click on a Javascript link that pops up a window, and I could use verifytitle on that window.  With the HtmlUnit version, we had some problems because some of our pages contained invalid Javascript, and if that happens your WebTest script will get an exception.  It forced us to clean up our Javascript.  We don't use Javascript very much, but a new part of our system does use it some for navigation and to change appearance of items based on status, so we needed the HtmlUnit version.

I'm not a Java programmer, I'm using WebTest as a tester only, this is probably why I don't understand your issues very well.  Sorry!
-- Lisa


-------------- Original message from Costin <cos.de.gunoi@gmail.com>: -------------- 


> First of all, thanks for the response. 
> >I don't know of any doc related to Javascript, but there have been 
> lots of postings about it >lately on the mailing list, since the new 
> HtmlUnit-based WebTest has more Javascript >support. Some of the 
> discussion is on how things should be made to work, eg., 
> >http://lists.canoo.com/pipermail/webtest/2004q4/002721.html 
> I have loooked at this email but it didn't help anyways. It's says 
> something about the current response but it doesn't point to any 
> resources of JavaScript nor XML related things. 
> 
> >Other than that I don't know how to answer your question, but no 
> doubt someone will. I am >just now starting to use the HtmlUnit-based 
> WebTest on pages that have Javascript, and I'm >just using standard 
> XML WebTest files. I have been able to verify a title of a window 
> popped >up with Javascript, and click on Javascript buttons, that's as 
> far as I have gone. 
> >-- Lisa 
> How did you started using JavaScript support - through normal Java 
> files or XML files. Do you have some examples with the checks of the 
> Javascript button and/or window? 
> 
> If my assumpation is correct then JS is supported in WebTest only 
> through JavaCode. However, I think there could be some way to extend 
> the syntax in order to provide the needed functionality for JS into 
> XML file also. 
> 
> Any materials except the selftest and the rest of the source code? 
> 
> Thanks a lot. 
> Costin 
> _______________________________________________ 
> WebTest mailing list 
> WebTest@lists.canoo.com 
> http://lists.canoo.com/mailman/listinfo/webtest 
--NextPart_Webmail_9m3u9jl4l_14731_1100903299_0
Content-Type: text/html
Content-Transfer-Encoding: 8bit

<html>
<!-- BEGIN WEBMAIL STATIONERY -->
<head></head>
<body>
<!-- WEBMAIL STATIONERY noneset -->
<DIV></DIV>
<DIV>Hi Costin,</DIV>
<DIV>I am just using the regular WebTest syntax, I'm afraid I don't really understand your question.&nbsp; For example, I did a test where I used clicklink to click on a Javascript link that pops up a window, and I could use verifytitle on that window.&nbsp; With the HtmlUnit version, we had some problems because some of our pages contained invalid Javascript, and if that happens your WebTest script will get an exception.&nbsp; It forced us to clean up our Javascript.&nbsp; We don't use Javascript very much, but a new part of our system does use it some for navigation and to change appearance of items based on status, so we needed the HtmlUnit version.</DIV>
<DIV>&nbsp;</DIV>
<DIV>I'm not a Java programmer, I'm using WebTest as a tester only, this is probably why I don't understand your issues very well.&nbsp; Sorry!</DIV>
<DIV>-- Lisa</DIV><BR>
<BLOCKQUOTE style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #1010ff 2px solid">-------------- Original message from Costin &lt;cos.de.gunoi@gmail.com&gt;: -------------- <BR><BR><BR>&gt; First of all, thanks for the response. <BR>&gt; &gt;I don't know of any doc related to Javascript, but there have been <BR>&gt; lots of postings about it &gt;lately on the mailing list, since the new <BR>&gt; HtmlUnit-based WebTest has more Javascript &gt;support. Some of the <BR>&gt; discussion is on how things should be made to work, eg., <BR>&gt; &gt;http://lists.canoo.com/pipermail/webtest/2004q4/002721.html <BR>&gt; I have loooked at this email but it didn't help anyways. It's says <BR>&gt; something about the current response but it doesn't point to any <BR>&gt; resources of JavaScript nor XML related things. <BR>&gt; <BR>&gt; &gt;Other than that I don't know how to answer your question, but no <BR>&gt; doubt someone will. I am &gt;just now starting to use the HtmlUnit-based <BR>&gt; WebTest on pages that have Javascript, and I'm &gt;just using standard <BR>&gt; XML WebTest files. I have been able to verify a title of a window <BR>&gt; popped &gt;up with Javascript, and click on Javascript buttons, that's as <BR>&gt; far as I have gone. <BR>&gt; &gt;-- Lisa <BR>&gt; How did you started using JavaScript support - through normal Java <BR>&gt; files or XML files. Do you have some examples with the checks of the <BR>&gt; Javascript button and/or window? <BR>&gt; <BR>&gt; If my assumpation is correct then JS is supported in WebTest only <BR>&gt; through JavaCode. However, I think there could be some way to extend <BR>&gt; the syntax in order to provide the needed functionality for JS into <BR>&gt; XML file also. <BR>&gt; <BR>&gt; Any materials except the selftest and the rest of the source code? <BR>&gt; <BR>&gt; Thanks a lot. <BR>&gt; Costin <BR>&gt; _______________________________________________ <BR>&gt; WebTest mailing list <BR>&gt; WebTest@lists.canoo.com <BR>&gt; http://lists.canoo.com/mailman/listinfo/webtest </BLOCKQUOTE>
<!-- END WEBMAIL STATIONERY -->

</body>
</html>

--NextPart_Webmail_9m3u9jl4l_14731_1100903299_0--