Return-Path: Delivered-To: apmail-incubator-harmony-dev-archive@www.apache.org Received: (qmail 86711 invoked from network); 25 Jan 2006 18:28:45 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 25 Jan 2006 18:28:45 -0000 Received: (qmail 5586 invoked by uid 500); 25 Jan 2006 18:28:33 -0000 Delivered-To: apmail-incubator-harmony-dev-archive@incubator.apache.org Received: (qmail 5468 invoked by uid 500); 25 Jan 2006 18:28:33 -0000 Mailing-List: contact harmony-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: harmony-dev@incubator.apache.org Delivered-To: mailing list harmony-dev@incubator.apache.org Received: (qmail 5451 invoked by uid 99); 25 Jan 2006 18:28:33 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [192.87.106.226] (HELO ajax.apache.org) (192.87.106.226) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Jan 2006 10:28:30 -0800 Received: from ajax.apache.org (ajax.apache.org [127.0.0.1]) by ajax.apache.org (Postfix) with ESMTP id 0D2F0E0 for ; Wed, 25 Jan 2006 19:28:10 +0100 (CET) Message-ID: <1023299422.1138213690052.JavaMail.jira@ajax.apache.org> Date: Wed, 25 Jan 2006 19:28:10 +0100 (CET) From: "Vladimir Strigun (JIRA)" To: harmony-dev@incubator.apache.org Subject: [jira] Commented: (HARMONY-45) Charset.isRegistered() method always return true In-Reply-To: <2124223559.1138213269410.JavaMail.jira@ajax.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N [ http://issues.apache.org/jira/browse/HARMONY-45?page=comments#action_12363987 ] Vladimir Strigun commented on HARMONY-45: ----------------------------------------- Testcase: package org.apache.harmony.tests.java.nio.charset; import java.nio.charset.Charset; import junit.framework.TestCase; public class CharsetTest extends TestCase { /** * @tests java.nio.charset.Charset#isRegistered() */ public void test_isRegistered() { Charset charset = Charset.forName("x-mac-cyrillic"); assertFalse("Assert 0: isRegistered() return true for \"x-mac-cyrillic\" charset ", charset.isRegistered()); charset = Charset.forName("US-ASCII"); assertTrue("Assert 1: isRegistered() return false for \"US-ASCII\" charset ", charset.isRegistered()); } } > Charset.isRegistered() method always return true > ------------------------------------------------ > > Key: HARMONY-45 > URL: http://issues.apache.org/jira/browse/HARMONY-45 > Project: Harmony > Type: Bug > Components: Classlib > Reporter: Vladimir Strigun > Priority: Trivial > > In accordance with J2SE specification method isRegistered() should return true only if charset is registered with IANA. > As well, "if a supported charset is not listed in the IANA registry then its canonical name must begin with one of the strings "X-" or "x-" > Testcase shows that even if charset name begin with "x-" isRegistered returns true; -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira