[icedtea-web] RFC: add unit tests for the jnlp parser

Andrew John Hughes ahughes at redhat.com
Tue Apr 5 05:12:41 PDT 2011


On Fri, Apr 01, 2011 at 05:54:32PM -0400, Omair Majid wrote:
> On 03/31/2011 04:56 PM, Dr Andrew John Hughes wrote:
> >On 15:30 Thu 31 Mar     , Omair Majid wrote:
> >>On 03/31/2011 02:26 PM, Dr Andrew John Hughes wrote:
> >>>On 13:40 Thu 31 Mar     , Omair Majid wrote:
> >>>>On 03/30/2011 08:21 PM, Dr Andrew John Hughes wrote:
> >>>>>
> >>>>>It does need documenting in README, but I'm happy for that to be a separate patch.
> >>>>
> >>>>Patch attached. Does that look okay?
> >>>>
> >>>
> >>>It's a bit brief.
> >>>
> >>>* What about documenting the --with-rhino/junit options?
> >>>* What about something specific about the JUnit tests?
> >>
> >>Okay, how about the new patch?
> >>
> >Still nothing on the JUnit stuff, which was the main reason I thought we were
> >patching the docs.  The custom output and the reasoning for it should be noted
> >IMHO.
> >
> 
> Ah, _now_ I get it. I thought by JUnit, you were referring to JUnit
> itself, not our frontend/formatter for it.
> 

Sorry, should have been clearer.

> I thought my documentation of that in tests/junit-runner/README was
> sufficient. Anyway, I have updated the README for that too. Any
> other suggestions?

Ok, I'd forgotten about that file.  The changes aren't in the patch below, though...

> 
> Cheers,
> Omair

> diff -r 1d604ccd9b6b README
> --- a/README	Thu Mar 31 18:19:31 2011 -0400
> +++ b/README	Fri Apr 01 12:43:20 2011 -0400
> @@ -66,6 +66,11 @@
>  
>  The plugin can be disabled by passing --disable-plugin.
>  
> +The following optional dependencies enable additional features
> +
> +* rhino (enables support for using proxy auto config files)
> +* junit4 (enables unit tests)
> +
>  See ./configure --help if you need to override the defaults.
>  
>  The following locations are checked for a JDK:
> @@ -113,10 +118,50 @@
>  These are documented fully in the relevant section below.
>  
>  * --disable-plugin: Don't build the browser plugin.
> +* --with-rhino: Specify the location of rhino jar
> +* --with-junit: Specify the location of the junit 4 jar
> +
> +Rhino Support
> +=============
> +
> +IcedTea-Web needs rhino for using Proxy Auto Config (PAC) files. If rhino is
> +not found, or explicitly disabled, then support for PAC files will be disabled.
> +
> +By default, the following paths are checked for rhino:
> +  - /usr/share/java/js.jar
> +  - /usr/share/rhino-1.6/lib/js.jar
> +  - /usr/share/java/rhino.jar
> +
> +If a rhino jar is not found, rhino support is disabled. The --with-rhino build
> +option can be used to specify the location of the jar file. To explicitly
> +disable rhino use --with-rhino=no.
> +
> +JUnit Support
> +=============
> +
> +JUnit is needed for running some tests. It has no run-time impact.
> +
> +By default, the following paths are checked:
> +  - /usr/share/java/junit4.jar
> +
> +If JUnit is not found, JUnit support is disabled. The --with-junit option can
> +be used to specify the location of the JUnit 4 jar. To disable JUnit support
> +explicitly, use --with-junit=no.
> +
> +A custom JUnit ouput formatter is supplied. This makes the output of JUnit
> +tests match the output of other tests. A simple 'Passed:' or 'FAILED:' is
> +printed out, followed by <TestClass>.<testMethod>. This is also the format used
> +by JTreg.
>  
>  Testing
>  =======
>  
> +A set of automated tests is supplied for IcedTea-Web. They can be run by using
> +'make check'. Currently, this only tests a few parts of IcedTea-Web.
> +
> +The number and type of tests run by 'make check' may be affected by the build
> +options, including JUnit support and rhino support.
> +
>  A test suite is supplied for the browser plugin.  It can be built
>  using 'make plugin-tests' and run by loading the HTML page specified
>  into a browser with the plugin installed.


-- 
Andrew :)

Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

Support Free Java!
Contribute to GNU Classpath and IcedTea
http://www.gnu.org/software/classpath
http://icedtea.classpath.org
PGP Key: F5862A37 (https://keys.indymedia.org/)
Fingerprint = EA30 D855 D50F 90CD F54D  0698 0713 C3ED F586 2A37



More information about the distro-pkg-dev mailing list