X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/46f4442e9a5a4f3b98b7c1083586332f6a8a99a4..51004dcb01e06fef634b61be77ed73dd61cb6db9:/icuSources/test/intltest/restsnew.cpp?ds=sidebyside diff --git a/icuSources/test/intltest/restsnew.cpp b/icuSources/test/intltest/restsnew.cpp index 8aa604b0..dbba4703 100644 --- a/icuSources/test/intltest/restsnew.cpp +++ b/icuSources/test/intltest/restsnew.cpp @@ -1,5 +1,5 @@ /******************************************************************** - * Copyright (c) 1997-2008, International Business Machines + * Copyright (c) 1997-2009, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************/ @@ -181,11 +181,16 @@ void NewResourceBundleTest::runIndexedTest( int32_t index, UBool exec, const cha { if (exec) logln("TestSuite ResourceBundleTest: "); switch (index) { +#if !UCONFIG_NO_FILE_IO && !UCONFIG_NO_LEGACY_CONVERSION case 0: name = "TestResourceBundles"; if (exec) TestResourceBundles(); break; case 1: name = "TestConstruction"; if (exec) TestConstruction(); break; case 2: name = "TestIteration"; if (exec) TestIteration(); break; case 3: name = "TestOtherAPI"; if(exec) TestOtherAPI(); break; case 4: name = "TestNewTypes"; if(exec) TestNewTypes(); break; +#else + case 0: case 1: case 2: case 3: case 4: name = "skip"; break; +#endif + case 5: name = "TestGetByFallback"; if(exec) TestGetByFallback(); break; default: name = ""; break; //needed to end loop } @@ -200,7 +205,7 @@ NewResourceBundleTest::TestResourceBundles() loadTestData(status); if(U_FAILURE(status)) { - dataerrln("[DATA] Could not load testdata.dat %s " + UnicodeString(u_errorName(status))); + dataerrln("Could not load testdata.dat %s " + UnicodeString(u_errorName(status))); return; } @@ -234,7 +239,7 @@ NewResourceBundleTest::TestConstruction() testdatapath=loadTestData(err); if(U_FAILURE(err)) { - dataerrln("[DATA] Could not load testdata.dat %s " + UnicodeString(u_errorName(err))); + dataerrln("Could not load testdata.dat %s " + UnicodeString(u_errorName(err))); return; } @@ -309,7 +314,7 @@ NewResourceBundleTest::TestIteration() testdatapath=loadTestData(err); if(U_FAILURE(err)) { - dataerrln("[DATA] Could not load testdata.dat %s " + UnicodeString(u_errorName(err))); + dataerrln("Could not load testdata.dat %s " + UnicodeString(u_errorName(err))); return; } @@ -428,7 +433,7 @@ NewResourceBundleTest::TestOtherAPI(){ if(U_FAILURE(err)) { - dataerrln("[DATA] Could not load testdata.dat %s " + UnicodeString(u_errorName(err))); + dataerrln("Could not load testdata.dat %s " + UnicodeString(u_errorName(err))); return; } @@ -463,7 +468,7 @@ NewResourceBundleTest::TestOtherAPI(){ ResourceBundle defaultresource(err); ResourceBundle explicitdefaultresource(NULL, Locale::getDefault(), err); if(U_FAILURE(err)){ - errln("Construction of default resourcebundle failed"); + errcheckln(err, "Construction of default resourcebundle failed - %s", u_errorName(err)); return; } // You can't compare the default locale to the resolved locale in the @@ -636,7 +641,7 @@ NewResourceBundleTest::testTag(const char* frag, testdatapath=loadTestData(status); if(U_FAILURE(status)) { - dataerrln("[DATA] Could not load testdata.dat %s " + UnicodeString(u_errorName(status))); + dataerrln("Could not load testdata.dat %s " + UnicodeString(u_errorName(status))); return FALSE; } @@ -1017,7 +1022,7 @@ NewResourceBundleTest::TestNewTypes() { if(U_FAILURE(status)) { - dataerrln("[DATA] Could not load testdata.dat %s \n",u_errorName(status)); + dataerrln("Could not load testdata.dat %s \n",u_errorName(status)); return; } @@ -1164,7 +1169,7 @@ NewResourceBundleTest::TestGetByFallback() { heRes.getWithFallback("calendar", status).getWithFallback("islamic-civil", status).getWithFallback("eras", status); if(U_FAILURE(status)) { - errln("Didn't get Islamic Eras. I know they are there!\n"); + dataerrln("Didn't get Islamic Eras. I know they are there! - %s", u_errorName(status)); } status = U_ZERO_ERROR;