Re: httpunit 1.7.1 release to Maven central - request for test and fix
Wolfgang Fahl <[email protected]> Wed, 12 Sep 2012 15:33:35 +0200
| Newsgroups | gmane.comp.web.httpunit.devel |
|---|---|
| Organization | BITPlan GmbH |
| Message-ID | <[email protected]> |
This is a multi-part message in MIME format.
--===============3171961931118435756==
Content-Type: multipart/alternative;
boundary="------------000109000902050903030003"
This is a multi-part message in MIME format.
--------------000109000902050903030003
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
Warwick,
thank you so much for this.
I have focussed on ServletAccessTest for a start. It looks like this
testcase can not be run on it's own.
testServletParameters(com.meterware.servletunit.ServletAccessTest) Time
elapsed: 0.004 sec <<< ERROR!
java.lang.NullPointerException
at
com.meterware.servletunit.ServletUnitClient.newInvocation(ServletUnitClient.java:82)
at
setInvocationContextFactory is not called before calling newClient().
Instead of a null pointer exception there will be a RunTimeException now
and it's checked that setInvocationContextFactory has a non-null parameter.
/**
* set the invocation context factory to be used
* @param invocationContextFactory
*/
static void setInvocationContextFactory( InvocationContextFactory
invocationContextFactory ) {
if (invocationContextFactory==null)
throw new RuntimeException("setInvocationContextFactory
called with null invocationContextFactory parameter");
_invocationContextFactory = invocationContextFactory;
}
Russ - how do we get a proper InvocationContextFactory setup for
ServletAccessTest?
Yours
Wolfgang
Am 12.09.12 13:49, schrieb Warwick Hunter:
> *Fedora 16 x86_64 Quad Core*
>
> I only tested the 1085 revision. Let me know if you want me to do more.
>
> Tests in error:
> testServletParameters(com.meterware.servletunit.ServletAccessTest)
> testTitle(com.meterware.httpunit.WebPageTest): Invalid Http response
>
> Tests run: 813, Failures: 0, Errors: 2, Skipped: 8
>
> Details attached.
>
> Warwick
>
> Dear httpunit developers,
>
> Kai has proposed to upload the current state of httpunit to the
> central maven repository.
> Russell has than modified the project content to better support
> maven. Unfortunately the test cases did not run through reliably
> and as a first measure Russell has converted the tests to JUnit 4
> (see below)
>
> I'd like to ask all httpunit developers to help test and fix the
> current httpunit state.
>
> Please find below a script which can test multiple httpunit
> revisions using maven. Currently we are interested in the revison 1085
> test results and ways to fix the remaining problems.
>
> To test only revision 1085 the following commands will do:
>
> svn checkout -r 1085
> https://httpunit.svn.sourceforge.net/svnroot/httpunit/trunk/httpunit
> httpunit1085
> cd httpunit1085
> mvn test
>
> Thank you for your support
>
> Yours
> Wolfgang
>
>
> # test different versions of httpunit
> # to check for regression
> # WF 2009-10-05
> # retest 2012-09-06
> root=`pwd`
> #r=971
> r=1085
> while [ $r -le 1085 ]
> do
> date=`date`
> echo testing $r at $date
> cd $root
> svn checkout -r $r
> https://httpunit.svn.sourceforge.net/svnroot/httpunit/trunk/httpunit
> httpunit$r > /dev/null
> cd httpunit$r
> mvn test > ../htestresult.$r
> grep FAILURE ../htestresult.$r
> echo done
> r=`expr $r + 1`
> done
>
> I have now converted the tests to JUnit4 and am initializing the
> pseudoserver once per class rather than once per test. This speeds
> up the tests slightly (about 15%) and makes them much more
> reliable. On the other hand, it does mean that the tests can be
> slightly interdependent - resource names should be made unique
> between tests. What I see now is that there are two tests which
> appear to be failing intermittently:
>>
>> WebClientTest.testInternalErrorException
>> WebImageTest.testGetImage
>>
>> It might be worth taking a look to see if you are seeing the same
>> behavior and if you have any ideas on how to fix it.
>>
> rev 1085 has the following results here:
>
> *Ubuntu 12.04 LTS Quad Core 2.3 GHz:**
> *Tests run: 813, Failures: 0, Errors: 0, Skipped: 8
> [INFO] Total time: 18.200s
>
> *Mac OS Tiger Quad Core 2 GHz:*
> Failed tests:
>
> testInternalErrorException(com.meterware.httpunit.WebClientTest):
> Should have rejected the request
>
> Tests run: 813, *Failures: 1*, Errors: 0, Skipped: 8
> [INFO] BUILD FAILURE
> [INFO] Total time: 20.650s
>
> *Windows XP virtual machine in Mac OS Quad Core env:**
> *Tests hang at Running com.meterware.httpunit.WebPageTest ... and
> one failure before that:
>
> Tests run: 38, Failures: 1, Errors: 0, Skipped: 3, Time elapsed:
> 1.781 sec <<< FAILURE!
> Running com.meterware.httpunit.WebFormTest
>
>
> --
>
> BITPlan - smart solutions
> Wolfgang Fahl
> Pater-Delp-Str. 1, D-47877 Willich Schiefbahn
> Tel. +49 2154 811-480 <tel:%2B49%202154%20811-480>, Fax +49 2154 811-481 <tel:%2B49%202154%20811-481>
> Web: http://www.bitplan.de
> BITPlan GmbH, Willich - HRB 6820 Krefeld, Steuer-Nr.: 10258040548, Geschäftsführer: Wolfgang Fahl
>
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond.
> Discussions
> will include endpoint security, mobile security and the latest in
> malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> Httpunit-develop mailing list
> [email protected]
> <mailto:[email protected]>
> https://lists.sourceforge.net/lists/listinfo/httpunit-develop
>
>
>
>
> --
> Warwick Hunter
> K1300S m: +61 4 1242 1576 skype: warwickhunter
>
>
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>
>
> _______________________________________________
> Httpunit-develop mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/httpunit-develop
--
BITPlan - smart solutions
Wolfgang Fahl
Pater-Delp-Str. 1, D-47877 Willich Schiefbahn
Tel. +49 2154 811-480, Fax +49 2154 811-481
Web: http://www.bitplan.de
BITPlan GmbH, Willich - HRB 6820 Krefeld, Steuer-Nr.: 10258040548, Geschäftsführer: Wolfgang Fahl
--------------000109000902050903030003
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Warwick,<br>
<br>
thank you so much for this.<br>
I have focussed on ServletAccessTest for a start. It looks like this
testcase can not be run on it's own.<br>
<meta name="Titel" content="">
<p class="MsoPlainText">testServletParameters(com.meterware.servletunit.ServletAccessTest)<span
style="mso-spacerun: yes"> </span>Time elapsed: 0.004 sec<span
style="mso-spacerun: yes"> </span><<< ERROR!<br>
java.lang.NullPointerException<br>
<span style="mso-tab-count:1"> </span>at
com.meterware.servletunit.ServletUnitClient.newInvocation(ServletUnitClient.java:82)<br>
<span style="mso-bidi-font-size:12.0pt"><span
style="mso-tab-count:1"> </span>at
</span></p>
<meta name="Stichwörter" content="">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<meta name="ProgId" content="Word.Document">
<meta name="Generator" content="Microsoft Word 2008">
<meta name="Originator" content="Microsoft Word 2008">
<link rel="File-List"
href="file://localhost/Users/wf/Library/Caches/TemporaryItems/msoclip/0clip_filelist.xml">
<!--[if gte mso 9]><xml>
<o:DocumentProperties>
<o:Template>Normal.dotm</o:Template>
<o:Revision>0</o:Revision>
<o:TotalTime>0</o:TotalTime>
<o:Pages>1</o:Pages>
<o:Words>32</o:Words>
<o:Characters>188</o:Characters>
<o:Company>BITPlan GmbH</o:Company>
<o:Lines>1</o:Lines>
<o:Paragraphs>1</o:Paragraphs>
<o:CharactersWithSpaces>230</o:CharactersWithSpaces>
<o:Version>12.0</o:Version>
</o:DocumentProperties>
<o:OfficeDocumentSettings>
<o:AllowPNG/>
</o:OfficeDocumentSettings>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:WordDocument>
<w:Zoom>0</w:Zoom>
<w:TrackMoves>false</w:TrackMoves>
<w:TrackFormatting/>
<w:HyphenationZone>21</w:HyphenationZone>
<w:PunctuationKerning/>
<w:DrawingGridHorizontalSpacing>18 pt</w:DrawingGridHorizontalSpacing>
<w:DrawingGridVerticalSpacing>18 pt</w:DrawingGridVerticalSpacing>
<w:DisplayHorizontalDrawingGridEvery>0</w:DisplayHorizontalDrawingGridEvery>
<w:DisplayVerticalDrawingGridEvery>0</w:DisplayVerticalDrawingGridEvery>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:DontGrowAutofit/>
<w:DontAutofitConstrainedTables/>
<w:DontVertAlignInTxbx/>
</w:Compatibility>
</w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" LatentStyleCount="276">
</w:LatentStyles>
</xml><![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
{font-family:Cambria;
panose-1:2 4 5 3 5 4 6 3 2 4;
mso-font-charset:0;
mso-generic-font-family:auto;
mso-font-pitch:variable;
mso-font-signature:3 0 0 0 1 0;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{mso-style-parent:"";
margin:0cm;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-ascii-font-family:Cambria;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:Cambria;
mso-fareast-theme-font:minor-latin;
mso-hansi-font-family:Cambria;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;
mso-fareast-language:EN-US;}
p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
{mso-style-link:"Nur Text Zeichen";
margin:0cm;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.5pt;
font-family:"Times New Roman";
mso-ascii-font-family:Courier;
mso-fareast-font-family:Cambria;
mso-fareast-theme-font:minor-latin;
mso-hansi-font-family:Courier;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;
mso-fareast-language:EN-US;}
span.NurTextZeichen
{mso-style-name:"Nur Text Zeichen";
mso-style-locked:yes;
mso-style-link:"Nur Text";
mso-ansi-font-size:10.5pt;
mso-bidi-font-size:10.5pt;
font-family:Courier;
mso-ascii-font-family:Courier;
mso-hansi-font-family:Courier;}
@page Section1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 2.0cm 70.85pt;
mso-header-margin:36.0pt;
mso-footer-margin:36.0pt;
mso-paper-source:0;}
div.Section1
{page:Section1;}
-->
</style><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Normale Tabelle";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-parent:"";
mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
mso-para-margin:0cm;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-ascii-font-family:Cambria;
mso-ascii-theme-font:minor-latin;
mso-hansi-font-family:Cambria;
mso-hansi-theme-font:minor-latin;
mso-fareast-language:EN-US;}
</style>
<![endif]--><!--StartFragment--><!--EndFragment--><br>
setInvocationContextFactory is not called before calling
newClient(). Instead of a null pointer exception there will be a
RunTimeException now and it's checked that
setInvocationContextFactory has a non-null parameter.<br>
<br>
/**<br>
* set the invocation context factory to be used<br>
* @param invocationContextFactory<br>
*/<br>
static void setInvocationContextFactory(
InvocationContextFactory invocationContextFactory ) {<br>
if (invocationContextFactory==null)<br>
throw new RuntimeException("setInvocationContextFactory
called with null invocationContextFactory parameter");<br>
_invocationContextFactory = invocationContextFactory;<br>
}<br>
<br>
Russ - how do we get a proper InvocationContextFactory setup for
ServletAccessTest?<br>
<br>
Yours<br>
Wolfgang<br>
<div class="moz-cite-prefix">Am 12.09.12 13:49, schrieb Warwick
Hunter:<br>
</div>
<blockquote
cite="mid:CAFkvFFSBeumuW3y2JOpwa_Kbkpe=2k-FEmbRf0weYFQkGmtN4w@mail.gmail.com"
type="cite">
<div><b>Fedora 16 x86_64 Quad Core</b></div>
<div><br>
</div>
<div>I only tested the 1085 revision. Let me know if you want me
to do more.</div>
<div><br>
</div>
<div>Tests in error: </div>
<div>
testServletParameters(com.meterware.servletunit.ServletAccessTest)</div>
<div> testTitle(com.meterware.httpunit.WebPageTest): Invalid Http
response</div>
<div><br>
</div>
<div>Tests run: 813, Failures: 0, Errors: 2, Skipped: 8</div>
<div><br>
</div>
<div>Details attached.</div>
<div><br>
</div>
<div>Warwick</div>
<div><br>
</div>
<div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">Dear httpunit
developers,<br>
<br>
Kai has proposed to upload the current state of httpunit to
the central maven repository.<br>
Russell has than modified the project content to better
support maven. Unfortunately the test cases did not run
through reliably<br>
and as a first measure Russell has converted the tests to
JUnit 4 (see below)<br>
<br>
I'd like to ask all httpunit developers to help test and fix
the current httpunit state.<br>
<br>
Please find below a script which can test multiple httpunit
revisions using maven. Currently we are interested in the
revison 1085<br>
test results and ways to fix the remaining problems. <br>
<br>
To test only revision 1085 the following commands will do:<br>
<blockquote> svn checkout -r 1085 <a moz-do-not-send="true"
href="https://httpunit.svn.sourceforge.net/svnroot/httpunit/trunk/httpunit"
target="_blank">https://httpunit.svn.sourceforge.net/svnroot/httpunit/trunk/httpunit</a>
httpunit1085<br>
cd httpunit1085<br>
mvn test<br>
</blockquote>
Thank you for your support<br>
<br>
Yours<br>
Wolfgang<br>
<br>
<br>
# test different versions of httpunit<br>
# to check for regression<br>
# WF 2009-10-05<br>
# retest 2012-09-06<br>
root=`pwd`<br>
#r=971<br>
r=1085<br>
while [ $r -le 1085 ]<br>
do<br>
date=`date`<br>
echo testing $r at $date<br>
cd $root<br>
svn checkout -r $r <a moz-do-not-send="true"
href="https://httpunit.svn.sourceforge.net/svnroot/httpunit/trunk/httpunit"
target="_blank">https://httpunit.svn.sourceforge.net/svnroot/httpunit/trunk/httpunit</a>
httpunit$r > /dev/null<br>
cd httpunit$r<br>
mvn test > ../htestresult.$r<br>
grep FAILURE ../htestresult.$r<br>
echo done<br>
r=`expr $r + 1`<br>
done<br>
<br>
I have now converted the tests to JUnit4 and am initializing
the pseudoserver once per class rather than once per test.
This speeds up the tests slightly (about 15%) and makes them
much more reliable. On the other hand, it does mean that the
tests can be slightly interdependent - resource names should
be made unique between tests. What I see now is that there
are two tests which appear to be failing intermittently:
<blockquote type="cite">
<div><br>
</div>
<div>WebClientTest.testInternalErrorException</div>
<div>WebImageTest.testGetImage</div>
<div><br>
</div>
<div>It might be worth taking a look to see if you are
seeing the same behavior and if you have any ideas on
how to fix it.</div>
<div><br>
</div>
</blockquote>
rev 1085 has the following results here:<br>
<br>
<b>Ubuntu 12.04 LTS Quad Core 2.3 GHz:</b><b><br>
</b>Tests run: 813, Failures: 0, Errors: 0, Skipped: 8<br>
[INFO] Total time: 18.200s<br>
<br>
<b>Mac OS Tiger Quad Core 2 GHz:</b><br>
Failed tests:<br>
testInternalErrorException(com.meterware.httpunit.WebClientTest):
Should have rejected the request<br>
<br>
Tests run: 813, <b>Failures: 1</b>, Errors: 0, Skipped: 8<br>
[INFO] BUILD FAILURE<br>
[INFO] Total time: 20.650s<br>
<br>
<b>Windows XP virtual machine in Mac OS Quad Core env:</b><b><br>
</b>Tests hang at Running com.meterware.httpunit.WebPageTest
... and one failure before that:<br>
<br>
Tests run: 38, Failures: 1, Errors: 0, Skipped: 3, Time
elapsed: 1.781 sec <<< FAILURE!<br>
Running com.meterware.httpunit.WebFormTest<span
class="HOEnZb"><font color="#888888"><br>
<br>
<br>
<pre cols="72">--
BITPlan - smart solutions
Wolfgang Fahl
Pater-Delp-Str. 1, D-47877 Willich Schiefbahn
Tel. <a moz-do-not-send="true" href="tel:%2B49%202154%20811-480" value="+492154811480" target="_blank">+49 2154 811-480</a>, Fax <a moz-do-not-send="true" href="tel:%2B49%202154%20811-481" value="+492154811481" target="_blank">+49 2154 811-481</a>
Web: <a moz-do-not-send="true" href="http://www.bitplan.de" target="_blank">http://www.bitplan.de</a>
BITPlan GmbH, Willich - HRB 6820 Krefeld, Steuer-Nr.: 10258040548, Geschäftsführer: Wolfgang Fahl </pre>
</font></span></div>
<br>
------------------------------------------------------------------------------<br>
Live Security Virtual Conference<br>
Exclusive live event will cover all the ways today's security
and<br>
threat landscape has changed and how IT managers can respond.
Discussions<br>
will include endpoint security, mobile security and the latest
in malware<br>
threats. <a moz-do-not-send="true"
href="http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/"
target="_blank">http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/</a><br>
_______________________________________________<br>
Httpunit-develop mailing list<br>
<a moz-do-not-send="true"
href="mailto:[email protected]">[email protected]</a><br>
<a moz-do-not-send="true"
href="https://lists.sourceforge.net/lists/listinfo/httpunit-develop"
target="_blank">https://lists.sourceforge.net/lists/listinfo/httpunit-develop</a><br>
<br>
</blockquote>
</div>
<br>
<br clear="all">
<div><br>
</div>
-- <br>
Warwick Hunter<br>
K1300S m: +61 4 1242 1576 skype: warwickhunter<br>
<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. <a class="moz-txt-link-freetext" href="http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/">http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/</a></pre>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
Httpunit-develop mailing list
<a class="moz-txt-link-abbreviated" href="mailto:[email protected]">[email protected]</a>
<a class="moz-txt-link-freetext" href="https://lists.sourceforge.net/lists/listinfo/httpunit-develop">https://lists.sourceforge.net/lists/listinfo/httpunit-develop</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
BITPlan - smart solutions
Wolfgang Fahl
Pater-Delp-Str. 1, D-47877 Willich Schiefbahn
Tel. +49 2154 811-480, Fax +49 2154 811-481
Web: <a class="moz-txt-link-freetext" href="http://www.bitplan.de">http://www.bitplan.de</a>
BITPlan GmbH, Willich - HRB 6820 Krefeld, Steuer-Nr.: 10258040548, Geschäftsführer: Wolfgang Fahl </pre>
</body>
</html>
--------------000109000902050903030003--
--===============3171961931118435756==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
--===============3171961931118435756==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
_______________________________________________
Httpunit-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/httpunit-develop
--===============3171961931118435756==--