JDK-6236722 : JCK1.5a: /api/java_awt/datatransfer/DataFlavor/BestTests[DataFlavor2024,DataFlavor2025] failed
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 6
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: linux
  • CPU: generic
  • Submitted: 2005-03-07
  • Updated: 2012-03-23
  • Resolved: 2005-04-18
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6
6 b33Fixed
Related Reports
Relates :  
Description
Filed by	 : J2SE-SQA team (###@###.###)
J2SE             : Failed: 1.6.0b26[Mustang b26]
                   Pass:1.6.0b25[Mustangb25]
JCK              : Fail:JCK1.5a-runtime,JCK1.5-runtime                  
Platform[s]      : Faled: Solaris,Linux,cinnabar
switch/Mode      : All
JCK test owner   : http://javaweb.sfbay/jcce/tcks/jck/docs/others/owners.jto 

Failling Test:
=============
/api/java_awt/datatransfer/DataFlavor/BestTests
Test source location:
=====================
Attached

JTR file Location:
==================
Attached

How to reproduce:
==================
Script Attached

Error Message:
===============
DataFlavor2018: Passed. OK
DataFlavor2019: Passed. OK
DataFlavor2020: Passed. OK
DataFlavor2021: Passed. OK
DataFlavor2022: Passed. OK
DataFlavor2023: Passed. OK
DataFlavor2024: Failed. Bad return flavor: 0java.awt.datatransfer.DataFlavor[mimetype=text/wow;representationclass=java.io.InputStream;charset=US-ASCII]US-ASCIIDataFlavor2025: Failed. Bad return flavor: 0java.awt.datatransfer.DataFlavor[mimetype=text/wow;representationclass=java.io.InputStream;charset=US-ASCII]US-ASCIIDataFlavor2026: Passed. OK
DataFlavor2027: Passed. OK
DataFlavor2028: Passed. OK
DataFlavor2029: Passed. OK
STATUS:Failed.test cases: 13; passed: 11; failed: 2; first test case failure: DataFlavor2024

Specific Machine Info:
========================
Linux circuslv 2.6.9-5.EL #1 Wed Jan 5 19:22:18 EST 2005 i686 i686 i386 GNU/Linux

SunOS nyny 5.8 Generic_108528-29 sun4u sparc SUNW,Ultra-60







###@###.### 2005-03-07 03:17:13 GMT
###@###.### 2005-03-07 03:35:28 GMT
###@###.### 2005-03-16 19:39:38 GMT

Comments
SUGGESTED FIX Wrap encoding names (which are supposed to be canonical) into calls of the method that returns the canonical name of the encoding for its alias. --- DataTransferer.java Thu Mar 10 16:25:59 2005 *************** *** 2283,2296 **** HashMap charsetsMap = new HashMap(8, 1.0f); // we prefer Unicode charsets ! charsetsMap.put("Unicode", Integer.valueOf(3)); ! charsetsMap.put("UnicodeLittleUnmarked", Integer.valueOf(4)); ! charsetsMap.put("UnicodeBigUnmarked", Integer.valueOf(5)); ! charsetsMap.put("UTF8", Integer.valueOf(6)); ! charsetsMap.put("UTF16", Integer.valueOf(7)); ! // ASCII is the worst charset supported ! charsetsMap.put("ASCII", WORST_CHARSET_INDEX); String defEncoding = DataTransferer.canonicalName (DataTransferer.getDefaultTextCharset()); --- 2283,2295 ---- HashMap charsetsMap = new HashMap(8, 1.0f); // we prefer Unicode charsets ! charsetsMap.put(canonicalName("UTF-16LE"), Integer.valueOf(4)); ! charsetsMap.put(canonicalName("UTF-16BE"), Integer.valueOf(5)); ! charsetsMap.put(canonicalName("UTF-8"), Integer.valueOf(6)); ! charsetsMap.put(canonicalName("UTF-16"), Integer.valueOf(7)); ! // US-ASCII is the worst charset supported ! charsetsMap.put(canonicalName("US-ASCII"), WORST_CHARSET_INDEX); String defEncoding = DataTransferer.canonicalName (DataTransferer.getDefaultTextCharset()); ###@###.### 2005-03-11 12:47:26 GMT
09-03-2005

EVALUATION Most probably caused by switching to nio from sun.io: 4954004 was integrated in b26. ###@###.### 2005-03-09 10:49:36 GMT Indeed, canonical names of encodings were changed with switching to nio, but some hardcoded encoding names, that are supposed to be canonical, were left unchannged. ###@###.### 2005-03-09 14:53:27 GMT
09-03-2005