You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Mark Hindess (JIRA)" <ji...@apache.org> on 2010/05/27 23:51:38 UTC

[jira] Created: (HARMONY-6527) [classlib][text] CollationElementIterator tests fail

[classlib][text] CollationElementIterator tests fail
----------------------------------------------------

                 Key: HARMONY-6527
                 URL: https://issues.apache.org/jira/browse/HARMONY-6527
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
            Reporter: Mark Hindess
             Fix For: 6.0M2, 5.0M14


I see three failures on windows and linux:

CollationElementIteratorTest testSetOffset Failure expected:<1> but was:<0>

 junit.framework.AssertionFailedError: expected:<1> but was:<0>
 at
 org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetOffset
 (CollationElementIteratorTest.java:170)
 at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)

CollationElementIteratorTest testSetTextString Failure expected:<1> but was:<0>

 junit.framework.AssertionFailedError: expected:<1> but was:<0>
 at
 org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextString
 (CollationElementIteratorTest.java:186)
 at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)

CollationElementIteratorTest testSetTextCharacterIterator Failure expected:<1> but was:<0>

 junit.framework.AssertionFailedError: expected:<1> but was:<0>
 at
 org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextCharacterIterator
 (CollationElementIteratorTest.java:202)
 at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)



-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (HARMONY-6527) [classlib][text] CollationElementIterator tests fail

Posted by "Mark Hindess (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-6527?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Hindess updated HARMONY-6527:
----------------------------------

    Fix Version/s:     (was: 6.0M2)

Removing incorrect fix-for version(s).


> [classlib][text] CollationElementIterator tests fail
> ----------------------------------------------------
>
>                 Key: HARMONY-6527
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6527
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Mark Hindess
>
> I see three failures on windows and linux:
> CollationElementIteratorTest testSetOffset Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetOffset
>  (CollationElementIteratorTest.java:170)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextString Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextString
>  (CollationElementIteratorTest.java:186)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextCharacterIterator Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextCharacterIterator
>  (CollationElementIteratorTest.java:202)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HARMONY-6527) [classlib][text] CollationElementIterator tests fail

Posted by "Hudson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-6527?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12916681#action_12916681 ] 

Hudson commented on HARMONY-6527:
---------------------------------

Integrated in Harmony-select-1.5-head-linux-x86_64 #126 (See [https://hudson.apache.org/hudson/job/Harmony-select-1.5-head-linux-x86_64/126/])
    Apply fix for HARMONY-6527 ([classlib][text] CollationElementIterator tests fail) - I believe this is a non-bug difference, so modify the test to expect ICU behaviour.


> [classlib][text] CollationElementIterator tests fail
> ----------------------------------------------------
>
>                 Key: HARMONY-6527
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6527
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Mark Hindess
>            Assignee: Oliver Deakin
>             Fix For: 6.0M4, 5.0M16
>
>
> I see three failures on windows and linux:
> CollationElementIteratorTest testSetOffset Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetOffset
>  (CollationElementIteratorTest.java:170)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextString Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextString
>  (CollationElementIteratorTest.java:186)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextCharacterIterator Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextCharacterIterator
>  (CollationElementIteratorTest.java:202)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HARMONY-6527) [classlib][text] CollationElementIterator tests fail

Posted by "Oliver Deakin (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-6527?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12916511#action_12916511 ] 

Oliver Deakin commented on HARMONY-6527:
----------------------------------------

This failure basically has the same cause as HARMONY-6524. The test essentially does the following:

 RuleBasedCollator rbColl = (RuleBasedCollator) Collator.getInstance(new Locale("es", "", "TRADITIONAL")); 
 String text = "cha";
 CollationElementIterator iterator = rbColl.getCollationElementIterator(text);
 iterator.setOffset(1);
 assertEquals(1, iterator.getOffset());

However the spec for setOffset() says:
"Sets the iterator to point to the collation element corresponding to the specified character (the parameter is a CHARACTER offset in the original string, not an offset into its corresponding sequence of collation elements). The value returned by the next call to next() will be the collation element corresponding to the specified position in the text. If that position is in the middle of a contracting character sequence, the result of the next call to next() is the collation element for that sequence. This means that getOffset() is not guaranteed to return the same value as was passed to a preceding call to setOffset()."

The key here is that "ch" in the chosen locale should be treated as a single collation element according to the example in the spec of CollationElementIterator. Because of this, I believe setOffset(1) should actually set the offset to 0 i.e. the 'c' in "ch", not the 'h'. The RI does not exhibit this behaviour but ICU does. I believe the RI's behaviour here is not correct to the spec but ICU's is, so the right thing to do is change these tests to expect an offset of 0 and file this as a non-bug difference.

> [classlib][text] CollationElementIterator tests fail
> ----------------------------------------------------
>
>                 Key: HARMONY-6527
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6527
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Mark Hindess
>            Assignee: Oliver Deakin
>
> I see three failures on windows and linux:
> CollationElementIteratorTest testSetOffset Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetOffset
>  (CollationElementIteratorTest.java:170)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextString Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextString
>  (CollationElementIteratorTest.java:186)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextCharacterIterator Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextCharacterIterator
>  (CollationElementIteratorTest.java:202)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (HARMONY-6527) [classlib][text] CollationElementIterator tests fail

Posted by "Mark Hindess (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-6527?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Hindess updated HARMONY-6527:
----------------------------------

    Fix Version/s:     (was: 5.0M14)

> [classlib][text] CollationElementIterator tests fail
> ----------------------------------------------------
>
>                 Key: HARMONY-6527
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6527
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Mark Hindess
>
> I see three failures on windows and linux:
> CollationElementIteratorTest testSetOffset Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetOffset
>  (CollationElementIteratorTest.java:170)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextString Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextString
>  (CollationElementIteratorTest.java:186)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextCharacterIterator Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextCharacterIterator
>  (CollationElementIteratorTest.java:202)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (HARMONY-6527) [classlib][text] CollationElementIterator tests fail

Posted by "Oliver Deakin (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-6527?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Oliver Deakin reassigned HARMONY-6527:
--------------------------------------

    Assignee: Oliver Deakin

> [classlib][text] CollationElementIterator tests fail
> ----------------------------------------------------
>
>                 Key: HARMONY-6527
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6527
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Mark Hindess
>            Assignee: Oliver Deakin
>
> I see three failures on windows and linux:
> CollationElementIteratorTest testSetOffset Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetOffset
>  (CollationElementIteratorTest.java:170)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextString Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextString
>  (CollationElementIteratorTest.java:186)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextCharacterIterator Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextCharacterIterator
>  (CollationElementIteratorTest.java:202)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HARMONY-6527) [classlib][text] CollationElementIterator tests fail

Posted by "Hudson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-6527?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12916700#action_12916700 ] 

Hudson commented on HARMONY-6527:
---------------------------------

Integrated in Harmony-1.5-head-linux-x86_64 #973 (See [https://hudson.apache.org/hudson/job/Harmony-1.5-head-linux-x86_64/973/])
    Apply fix for HARMONY-6527 ([classlib][text] CollationElementIterator tests fail) - I believe this is a non-bug difference, so modify the test to expect ICU behaviour.


> [classlib][text] CollationElementIterator tests fail
> ----------------------------------------------------
>
>                 Key: HARMONY-6527
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6527
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Mark Hindess
>            Assignee: Oliver Deakin
>             Fix For: 6.0M4, 5.0M16
>
>
> I see three failures on windows and linux:
> CollationElementIteratorTest testSetOffset Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetOffset
>  (CollationElementIteratorTest.java:170)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextString Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextString
>  (CollationElementIteratorTest.java:186)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextCharacterIterator Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextCharacterIterator
>  (CollationElementIteratorTest.java:202)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (HARMONY-6527) [classlib][text] CollationElementIterator tests fail

Posted by "Oliver Deakin (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-6527?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Oliver Deakin resolved HARMONY-6527.
------------------------------------

    Fix Version/s: 6.0M4
                   5.0M16
       Resolution: Fixed

Modified the testcase as described above at repo revision r1003109 - please verify it resolves the failures for you.

> [classlib][text] CollationElementIterator tests fail
> ----------------------------------------------------
>
>                 Key: HARMONY-6527
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6527
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Mark Hindess
>            Assignee: Oliver Deakin
>             Fix For: 6.0M4, 5.0M16
>
>
> I see three failures on windows and linux:
> CollationElementIteratorTest testSetOffset Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetOffset
>  (CollationElementIteratorTest.java:170)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextString Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextString
>  (CollationElementIteratorTest.java:186)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)
> CollationElementIteratorTest testSetTextCharacterIterator Failure expected:<1> but was:<0>
>  junit.framework.AssertionFailedError: expected:<1> but was:<0>
>  at
>  org.apache.harmony.text.tests.java.text.CollationElementIteratorTest.testSetTextCharacterIterator
>  (CollationElementIteratorTest.java:202)
>  at java.lang.reflect.VMReflection.invokeMethod(VMReflection.java)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.