ICU-11433 Fix some no data test failures
X-SVN-Rev: 37219
This commit is contained in:
parent
d4975a1818
commit
9401ac86a0
@ -1713,7 +1713,7 @@ static void TestParseErrorReturnValue(void) {
|
||||
UCalendar* cal;
|
||||
|
||||
df = udat_open(UDAT_DEFAULT, UDAT_DEFAULT, NULL, NULL, -1, NULL, -1, &status);
|
||||
if (!assertSuccess("udat_open()", &status)) {
|
||||
if (!assertSuccessCheck("udat_open()", &status, TRUE)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -362,6 +362,12 @@ void IntlTestRBNF::TestMultiplePluralRules() {
|
||||
Formattable result;
|
||||
UnicodeString resultStr;
|
||||
FieldPosition pos;
|
||||
|
||||
if (U_FAILURE(status)) {
|
||||
dataerrln("Unable to create formatter - %s", u_errorName(status));
|
||||
return;
|
||||
}
|
||||
|
||||
formatter.parse(formatter.format(1000.0, resultStr, pos, status), result, status);
|
||||
if (1000 != result.getLong() || resultStr != UNICODE_STRING_SIMPLE("one thousand")) {
|
||||
errln("RuleBasedNumberFormat did not return the correct value. Got: %d", result.getLong());
|
||||
|
@ -7777,6 +7777,10 @@ void NumberFormatTest::TestDoubleLimit11439() {
|
||||
void NumberFormatTest::TestFastPathConsistent11524() {
|
||||
UErrorCode status = U_ZERO_ERROR;
|
||||
NumberFormat *fmt = NumberFormat::createInstance("en", status);
|
||||
if (U_FAILURE(status) || fmt == NULL) {
|
||||
dataerrln("Failed call to NumberFormat::createInstance() - %s", u_errorName(status));
|
||||
return;
|
||||
}
|
||||
fmt->setMaximumIntegerDigits(INT32_MIN);
|
||||
UnicodeString appendTo;
|
||||
assertEquals("", "0", fmt->format(123, appendTo));
|
||||
|
@ -667,7 +667,7 @@ void RegionTest::TestAvailableTerritories() {
|
||||
UErrorCode status = U_ZERO_ERROR;
|
||||
StringEnumeration *availableTerritories = Region::getAvailable(URGN_TERRITORY, status);
|
||||
if (U_FAILURE(status)) {
|
||||
errln("Region::getAvailable(URGN_TERRITORY,status) failed: %s", u_errorName(status));
|
||||
dataerrln("Region::getAvailable(URGN_TERRITORY,status) failed: %s", u_errorName(status));
|
||||
return;
|
||||
}
|
||||
const Region *world = Region::getInstance("001",status);
|
||||
|
Loading…
Reference in New Issue
Block a user