ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Magesh Umasankar" <>
Subject Re: cvs commit: jakarta-ant/src/etc/testcases/taskdefs gzip.xml
Date Sat, 17 Nov 2001 21:03:24 GMT


>     <target name="test5">
>  -    <gzip src="." zipfile="gzip.tmp"/>
>  +    <gzip src="gzip.xml" zipfile="gzip.tmp"/>
>     </target>

I just wanted to bring to your attention that, in
addition to test5, test4 too needs to be fixed.

Snip from src/etc/testcases/taskdefs/gzip.xml:

  <target name="test4">
    <gzip src="." zipfile=""/>

and its equivalent test code:

    public void test4() { 
        expectBuildException("test4", "attribute zipfile invalid");

This test is aimed at catching an empty zipfile 
attribute.  But instead of supplying a valid src
attribute with an invalid zipfile argument, the code
does otherwise.  This leads to a problem in the sense 
that if src is checked first in (,
test4 will still fail, but with the wrong exception.
What I am trying to say is, irrespective of the order
in which the attributes are being validated, each
test here should concentrate on generating one
consistent exception.  I don't know if I have made my 
point clear enough, but here is what would solve this

  <target name="test4">
    <gzip src="gzip.xml" zipfile=""/>


To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message