Uploaded image for project: 'Harmony'
  1. Harmony
  2. HARMONY-6316 [drlvm] [jit] Errors and hang when running Commons Math 2.0 test suite
  3. HARMONY-6335

[classlib] [text] NumberFormat incorrectly parses numbers containing spaces

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 5.0M11
    • None
    • Classlib
    • None
    • Harmony M11

    Description

      import java.text.NumberFormat;
      import java.text.ParseException;
      import java.util.Locale;

      import junit.framework.TestCase;

      public class ParseTest extends TestCase {

      public void testNumberParser() throws ParseException

      { NumberFormat f = NumberFormat.getInstance(Locale.US); Number c = f.parse("1 2"); assertEquals(1, c.intValue()); }

      }

      On the RI this passes, whereas on Harmony it fails with:
      junit.framework.AssertionFailedError: expected:<1> but was:<12>

      Attachments

        Activity

          People

            Unassigned Unassigned
            tellison Tim Ellison
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: