Tim,

Are you looking at this FileTest now? I've looked over this test, and basically I think it's the test itself can be improved. If 8.3 filename is disabled, the test_getCanonicalPath and test_getCanonicalFile fails on both RI and Harmony. Look inside the tests, it creates a file "longfilename.tst" and "longfi~`.tst", and try to assert these two file returns same canonical path. My suggestions on this test are:

1. About platform issue, these two tests are windows specific, and there are quite a few other test cases in FileTest written like "if(onWindows) blabla", they should be separated to another platform dependent test cases, according to our test convention proposal

2. About long file name issue, I think these 8.3 file name tests are still valuable, I suggest to check the workstation's status at first, and if it supports 8.3 filename, go on the tests, otherwise just skip over this block, the status can be easily get by codes below: (suppose we got a resource test file named as "longfilename.res")

private boolean support8Dot3Filename(){
   return new File(basedir+"longfi~1.res").exists();
}

your comments?

Tim Ellison wrote:
Can you stick it into a JIRA?  I may have time to look into it.

Regards,
Tim

Richard Liang wrote:
Hello Nathan,

Yes. When I disable 8.3 filename support on my WinXP, I get the same error.
IMHO, our test case cannot assume whether the 8.3 filename is disabled
or not.

Richard.

Nathan Beyer wrote:
I'm running them through the Ant scripts.

ant -f make/build.xml test

I do have the 8.3 filename support disabled on my laptop, so I'm
wondering
if that's it.

-Nathan

-----Original Message-----
From: Richard Liang [mailto:[EMAIL PROTECTED]
Sent: Sunday, June 18, 2006 12:14 AM
To: harmony-dev@incubator.apache.org
Subject: Re: [classlib] tests.api.java.io.FileTest failures on
Windows XP

Hello Nathan ,

The test just pass on my eclipse. How do you execute this test?

Nathan Beyer wrote:
Does anyone else get the following failures when running the classlib
test
suite on Windows XP? I've been getting these for months and just
ignoring
them while I worked on other stuff, because they always happened.
Before
I
start digging into I wanted to see if anyone else is getting these
reports.
test_getCanonicalFileFailureTest 5: Incorrect File Returned:
C:\dev\harmony\classlib\modules\luni\bin\test\long-JDK2-
3\longdi~1\longfi~1.
tst

junit.framework.AssertionFailedError: Test 5: Incorrect File Returned:
C:\dev\harmony\classlib\modules\luni\bin\test\long-JDK2-
3\longdi~1\longfi~1.
tst at
tests.api.java.io.FileTest.test_getCanonicalFile(FileTest.java:783)
at

java.lang.reflect.AccessibleObject.invokeV(AccessibleObject.java:205)0.171

test_getCanonicalPathFailureTest 6: Incorrect Path Returned.
(C:\dev\harmony\classlib\modules\luni\bin\test\long-JDK2-3\longfi~1.tst
insteadof
C:\dev\harmony\classlib\modules\luni\bin\test\long-JDK2-
3\longfilenameJDK2-3
.tst)

junit.framework.AssertionFailedError: Test 6: Incorrect Path Returned.
(C:\dev\harmony\classlib\modules\luni\bin\test\long-JDK2-3\longfi~1.tst
insteadof
C:\dev\harmony\classlib\modules\luni\bin\test\long-JDK2-
3\longfilenameJDK2-3
.tst) at
tests.api.java.io.FileTest.test_getCanonicalPath(FileTest.java:867)
at
java.lang.reflect.AccessibleObject.invokeV(AccessibleObject.java:205)







--
Richard Liang
China Software Development Lab, IBM



---------------------------------------------------------------------
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Paulex Yang
China Software Development Lab
IBM



---------------------------------------------------------------------
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to