This is odd indeed.

I use Ant 1.6.5 and JUnit 3.8.1. 

Here is my Ant build output:

Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\svn-store\jakarta\commons\codec>ant jar test
Buildfile: build.xml

init:
     [echo] -------- commons-codec 1.4-dev --------

prepare:

static:

compile:
    [javac] Compiling 1 source file to
C:\svn-store\jakarta\commons\codec\target\classes
Terminate batch job (Y/N)? y

C:\svn-store\jakarta\commons\codec>ant clean jar test
Buildfile: build.xml

clean:
   [delete] Deleting directory C:\svn-store\jakarta\commons\codec\target
   [delete] Deleting directory C:\svn-store\jakarta\commons\codec\dist

init:
     [echo] -------- commons-codec 1.4-dev --------

prepare:
    [mkdir] Created dir: C:\svn-store\jakarta\commons\codec\target
    [mkdir] Created dir:
C:\svn-store\jakarta\commons\codec\target\classes
    [mkdir] Created dir: C:\svn-store\jakarta\commons\codec\target\conf
    [mkdir] Created dir: C:\svn-store\jakarta\commons\codec\target\tests
    [mkdir] Created dir:
C:\svn-store\jakarta\commons\codec\target\test-reports

static:
     [copy] Copying 1 file to
C:\svn-store\jakarta\commons\codec\target\conf

compile:
    [javac] Compiling 24 source files to
C:\svn-store\jakarta\commons\codec\target\classes
     [copy] Copying 6 files to
C:\svn-store\jakarta\commons\codec\target\classes

jar:
    [mkdir] Created dir: C:\svn-store\jakarta\commons\codec\dist
    [mkdir] Created dir:
C:\svn-store\jakarta\commons\codec\target\classes\META-INF
     [copy] Copying 1 file to
C:\svn-store\jakarta\commons\codec\target\classes\META-INF
      [jar] Building jar:
C:\svn-store\jakarta\commons\codec\dist\commons-codec-1.4-dev.jar

init:
     [echo] -------- commons-codec 1.4-dev --------

prepare:

static:

compile:

compile.tests:
    [javac] Compiling 17 source files to
C:\svn-store\jakarta\commons\codec\target\tests
    [javac]
C:\svn-store\jakarta\commons\codec\src\test\org\apache\commons\codec\lan
guage\SoundexTest.java:299: warning: getMaxLength() in
org.apache.commons.codec.language.Soundex has been depr
ecated
    [javac]         soundex.setMaxLength(soundex.getMaxLength());
    [javac]                                     ^
    [javac]
C:\svn-store\jakarta\commons\codec\src\test\org\apache\commons\codec\lan
guage\SoundexTest.java:299: warning: setMaxLength(int) in
org.apache.commons.codec.language.Soundex has been d
eprecated
    [javac]         soundex.setMaxLength(soundex.getMaxLength());
    [javac]                ^
    [javac]
C:\svn-store\jakarta\commons\codec\src\test\org\apache\commons\codec\lan
guage\SoundexTest.java:305: warning: setMaxLength(int) in
org.apache.commons.codec.language.Soundex has been d
eprecated
    [javac]         soundex.setMaxLength(2);
    [javac]                ^
    [javac]
C:\svn-store\jakarta\commons\codec\src\test\org\apache\commons\codec\net
\URLCodecTest.java:48: warning: getEncoding() in
org.apache.commons.codec.net.URLCodec has been deprecated
    [javac]         assertEquals(urlCodec.getEncoding(),
urlCodec.getDefaultCharset());
    [javac]                              ^
    [javac] 4 warnings

test:
    [junit] Running org.apache.commons.codec.StringEncoderComparatorTest
    [junit] Tests run: 4, Failures: 0, Errors: 0, Time elapsed: 0.03 sec
    [junit] Running org.apache.commons.codec.binary.Base64Test
    [junit] Tests run: 24, Failures: 0, Errors: 0, Time elapsed: 0.07
sec
    [junit] Running org.apache.commons.codec.binary.BinaryCodecTest
    [junit] Tests run: 13, Failures: 0, Errors: 0, Time elapsed: 0.11
sec
    [junit] Running org.apache.commons.codec.binary.HexTest
    [junit] Tests run: 12, Failures: 0, Errors: 0, Time elapsed: 0.4 sec
    [junit] Running org.apache.commons.codec.digest.DigestUtilsTest
    [junit] Tests run: 8, Failures: 0, Errors: 0, Time elapsed: 1.784
sec
    [junit] Running
org.apache.commons.codec.language.DoubleMetaphoneTest
    [junit] Tests run: 13, Failures: 0, Errors: 0, Time elapsed: 0.36
sec
    [junit] Running org.apache.commons.codec.language.MetaphoneTest
    [junit] Tests run: 32, Failures: 0, Errors: 0, Time elapsed: 0.32
sec
    [junit] Running org.apache.commons.codec.language.RefinedSoundexTest
    [junit] Tests run: 6, Failures: 0, Errors: 0, Time elapsed: 0.02 sec
    [junit] Running org.apache.commons.codec.language.SoundexTest
    [junit] Tests run: 25, Failures: 0, Errors: 0, Time elapsed: 0.02
sec
    [junit] Running org.apache.commons.codec.net.BCodecTest
    [junit] Tests run: 9, Failures: 0, Errors: 0, Time elapsed: 0.311
sec
    [junit] Running org.apache.commons.codec.net.QCodecTest
    [junit] Tests run: 12, Failures: 0, Errors: 0, Time elapsed: 0.171
sec
    [junit] Running
org.apache.commons.codec.net.QuotedPrintableCodecTest
    [junit] Tests run: 15, Failures: 0, Errors: 0, Time elapsed: 0.21
sec
    [junit] Running org.apache.commons.codec.net.RFC1522CodecTest
    [junit] Tests run: 2, Failures: 0, Errors: 0, Time elapsed: 0.02 sec
    [junit] Running org.apache.commons.codec.net.URLCodecTest
    [junit] Tests run: 16, Failures: 0, Errors: 0, Time elapsed: 0.141
sec

BUILD SUCCESSFUL
Total time: 1 minute 55 seconds

Gary

> -----Original Message-----
> From: Chris Black [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, February 15, 2006 3:06 PM
> To: Jakarta Commons Developers List
> Subject: Re: [Codec] accented character soundex revisited
> 
> I am running the latest, I even did a new svn co into a new directory
to
> check:
> mkdir codec2
> svn co
https://svn.apache.org/repos/asf/jakarta/commons/proper/codec/trunk
> cd codec2
> (set up build.properties to point to my junit.jar)
> ant clean jar test
> 
> Gives me a failure on SoundexTest. I am junning Sun Java 1.4.2_08_b03.
> 
> I am curious as to why it would fail for me but not you, only
> differences are java version and perhaps junit version (I am using
> v3.8.1).
> 
> Best,
> Chris
> 
> Gary Gregory wrote:
> 
> >Hello Chris:
> >
> >Welcome to Codec development.
> >
> >One obvious thing: Make sure you start with latest from SVN:
> >
> >https://svn.apache.org/repos/asf/jakarta/commons/proper/codec/trunk
> >
> >(as opposed to the 1.3 sources)
> >
> >
> >You mention unit test failures? When I run:
> >
> >ant clean jar test
> >
> >All unit tests pass.
> >
> >I am using Sun Java 1.4.2_10.
> >
> >Gary
> >
> >
> >
> >>-----Original Message-----
> >>From: Chris Black [mailto:[EMAIL PROTECTED]
> >>Sent: Wednesday, February 15, 2006 1:28 PM
> >>To: [email protected]
> >>Subject: [Codec] accented character soundex revisited
> >>
> >>Over 18 months ago there was a thread on this list about the proper
> >>handling of accented characters in the Soundex encoder in
> >>
> >>
> >commons-codec
> >
> >
> >>but it never seemed to get resolved. In addition, there are still
> >>failing unit tests that reference this issue in the current version
of
> >>the code. As someone who uses this code, I'd like to see all unit
> >>
> >>
> >tests
> >
> >
> >>passing, so I've done some investigation.
> >>As a refresher, there were three options discussed for the behavior
of
> >>the Soundex codec when it sees an accented character:
> >>1) Throw an IllegalArgumentException
> >>2) Drop it silently
> >>3) Replace it with the equivalent unaccented character
> >>
> >>Right now the code drops it silently, but the unit tests are
expecting
> >>an IllegalArgumentException. The code in Soundex.map(char ch) seems
to
> >>be trying to throw this exception, but it will never happen because
> >>
> >>
> >the
> >
> >
> >>characters passed to it from Soundex.soundex are from a String that
> >>
> >>
> >has
> >
> >
> >>gone through SoundexUtils.clean(String str) which removes all
> >>
> >>
> >characters
> >
> >
> >>that fail a Character.isCharacter(char ch) check (accented chars
fail
> >>this check, I, erm, checked). This means if we want to throw an
> >>IllegalArgumentException it must be done in SoundexUtils.clean, not
> >>Soundex.map.
> >>
> >>I think either behaviors 1 or 2 (drop silently, which is what we
> >>currently do) would be easy to implement and then change the unit
> >>
> >>
> >tests
> >
> >
> >>to match the behavior so all unit tests on commons-codec pass.
> >>
> >>If someone lets me know which behavior is desired I will submit a
> >>
> >>
> >patch.
> >
> >
> >>Note that behavior 2 only requires either removing the test cases or
> >>changing them to expect the same encoding as an empty string.
> >>
> >>References:
> >>http://issues.apache.org/bugzilla/show_bug.cgi?id=29080
> >>
> >>
> >>
>
>http://www.mail-archive.com/[email protected]/msg41974.htm
l
> >
> >
> >>Best,
> >>Chris
> >>
> >>
>
>>---------------------------------------------------------------------
> >>To unsubscribe, e-mail: [EMAIL PROTECTED]
> >>For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >>
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to