httpunit FAQ (updated version)

Wolfgang Fahl <[email protected]> Fri, 25 Mar 2011 07:57:19 +0100
Newsgroups gmane.comp.web.httpunit.devel
Organization BITPlan GmbH
Message-ID <[email protected]>
Dear httpunit developers and users,

Please let me know what other questions you'd like to see answered in 
this FAQ and I'll try to add them together with a decent answer.
Please read the parts on Questions #5 and #6 before submitting any 
proposed changes ... this will speed up things a lot.

Currently only about 3-4 out of 10 tracker or mailing list requests 
follow this procedure.
If we get this up to more than 60% it would be a good start so that the 
response time can improve again.

FAQ
===
1. Where can I get information on httpunit?
2. Where do i get the most recent version of httpunit
3. Where do I find examples for the use of httpunit?
4. How do I sign up for the developer mailing list?
5. How do I get support for httpunit?
6. How can I suggest modifications to httpunit?
7. How do I find a testcase to start from?
8. What is the development environment for httpunit?
9. What do I do if i have trouble using httpunit with JavaScript?
10. Who are the developers behing httpunit?
11. What is the current version of httpunit?

1. Where can I get information on httpunit?
-------------------------------------------
httpunit is an OpenSource Project and it is hosted on SourceForge at 
https://sourceforge.net/projects/httpunit.
There is a project homepage at http://www.httpunit.org/ which contains a 
limited set of documentation.
There is a general FAQ section at http://www.httpunit.org/doc/faq.html

2. Where do i get the most recent version of httpunit
-----------------------------------------------------
The most recent version of httpunit can be found in the Subversion 
repository.
The repository is explained at:
     https://sourceforge.net/scm/?type=svn&group_id=6550
the URL for it is:
     https://httpunit.svn.sourceforge.net/svnroot/httpunit/trunk/httpunit/

A nice browser front end for it is:
     http://httpunit.svn.sourceforge.net/viewvc/httpunit/trunk/httpunit/


3. Where do I find examples for the use of httpunit?
----------------------------------------------------
a) There is a "cookbook"
    http://www.httpunit.org/doc/cookbook.html
b) There is a tutorial:
    http://www.httpunit.org/doc/tutorial/index.html
c) There are examples delivered with httpunit and accesible via the
    subversion respository:
    
http://httpunit.svn.sourceforge.net/viewvc/httpunit/trunk/httpunit/examples/


4. How do I sign up for the developer mailing list?
---------------------------------------------------
via the link
     https://lists.sourceforge.net/lists/listinfo/httpunit-develop


5. How do I get support for httpunit?
-------------------------------------
This mailing list and the trackers on
     https://sourceforge.net/projects/httpunit/support
are a good point to start. Don't expect too much - you might want to get 
active yourself.

6. How can I suggest modifications to httpunit?
-----------------------------------------------
httpunit is strictly based on test-first development.

If you'd like to get it modified you might want to prove your point by 
showing what is not working and
how you would like it to work.

Doing this within the JUnit testsuite of httpunit is the preferred way. 
And providing the test source code first gives you much better chances 
of a quick response.

If you'd like to supply a minor change that is easy to understand and 
does not change anything or not much
  (e.g. adding a comment or changing the layout of a statement or doing 
an algorithm slightly different)
then it might be sufficient to show that the change does not break any 
of the existing test cases.
Don't count on this. A JUnit test case is your better option.

Please supply a testcase with the expected result for the feature you 
are asking for and we'll look into implementing it.
For a start you might want to get the trunk version from the
subversion repository (see 
https://sourceforge.net/scm/?type=svn&group_id=6550
and have a look at the source code of some of the more than 800 JUnit 
based testcases in there.

Eclipse workspace patch files are welcome - other formats are also o.k. 
but just a bit more work.

When you are ready you might want to attach the testcase (and if you 
already have started implementing it also the actual code)
to your feature request.

If you propose a change make sure that all testcases run so after the 
change there should be more
  testcases than before and none of them is broken / does not work any more.

This should give you a clue on what a proper testcase for httpunit looks 
like.
The main communication about further details of the development is via 
the httpunit developer mailinglist.


7. How do I find a testcase to start from?
------------------------------------------
a) To find such tests I usually set a break point at the
      function that I'd like to test and then run all tests from the 
HttpUnitSuite. When the debugger halts at the breakpoint you'll see 
which test(s) called the function.


b) Another option is to search the full source code of all tests for 
keywords that match what your are intending to do

c) A third option is to look in the tracker items
     https://sourceforge.net/tracker/?group_id=6550
     and look for a comparable issue. Then use the trackers id e.g. Bug 
report number to find a test case for it.

8. What is the development environment for httpunit?
----------------------------------------------------
You need a Java compiler and may be an Integrated Development 
Environment like Eclipse.

Currently httpunit is mostly tested on these operating systems:
- Windows XP, Windows 7
- Suse Linux 11.3
- The latest Mac OS X (10.6)
The test environment is Eclipse Ganymede with a JDK 1.6 compiler set to 
JDK 1.4 compatiblity mode (this is also what you'll find set up in the 
Subversion library)

People from this mailing list also test with command line Maven 
environments, NetBeans and what have you got (it would be good to get 
some examples named
here ... feel free to let me know your environment if it is an addition 
to the above)

9. What do I do if i have trouble using httpunit with JavaScript?
-----------------------------------------------------------------
HttpUnit 1.x support of Javascript is limited. There is a new Javascript 
engine in development but the development is almost stalled due to 
limited resources.
To work around the issue you might want to
- try the new scripting engine
- switch off javascript
- if you get an org.mozilla.javascript.EcmAError ... undefined ... find 
the missing javascript function, implement it and supply the patch for 
the community see "6. How can I suggest modifications to httpunit?"

10. Who are the developers behind httpunit?
-------------------------------------
Russell is the main developer of httpunit. He made it open source and 
dozens of people have since then supplied input e.g. in form of patches.
Wolfgang has been committer for a few years now - he concentrates on 
communicating with the developers and gathering patches.

11. What is the current version of httpunit?
------------------------------------
The 1.7 release available for download on Sourceforge is stable but does 
not have the set of patches since that release.
A maintainance release is due since mid 2010 and might show up anytime soon.

Thank you for reading these Frequently Asked Questions and Answers.

Yours
   Wolfgang

------------------------------------------------------------------------------
Enable your software for Intel(R) Active Management Technology to meet the
growing manageability and security demands of your customers. Businesses
are taking advantage of Intel(R) vPro (TM) technology - will your software 
be a part of the solution? Download the Intel(R) Manageability Checker 
today! http://p.sf.net/sfu/intel-dev2devmar