From fea6dbb22fc138ee11613f0b3a2835aedeae86a1 Mon Sep 17 00:00:00 2001 From: Travis Keep Date: Tue, 15 Jul 2014 18:18:39 +0000 Subject: [PATCH] ICU-10864 DecimalFormat::getGroupingSize() to return 0 when grouping isn't being used. X-SVN-Rev: 36028 --- icu4c/source/test/intltest/dcfmapts.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/icu4c/source/test/intltest/dcfmapts.cpp b/icu4c/source/test/intltest/dcfmapts.cpp index 850aa97dde..5eea883345 100644 --- a/icu4c/source/test/intltest/dcfmapts.cpp +++ b/icu4c/source/test/intltest/dcfmapts.cpp @@ -103,6 +103,14 @@ void IntlTestDecimalFormatAPI::testAPI(/*char *par*/) return; } + // bug 10864 + status = U_ZERO_ERROR; + DecimalFormat noGrouping("###0.##", status); + if (noGrouping.getGroupingSize() != 0) { + errln("Grouping size should be 0 for no grouping."); + } + // end bug 10864 + status = U_ZERO_ERROR; const UnicodeString pattern("#,##0.# FF"); DecimalFormat pat(pattern, status);