From e0b86b533439cd4aa72680bff64e1213f18a52d4 Mon Sep 17 00:00:00 2001 From: "Steven R. Loomis" Date: Wed, 5 Nov 2003 03:04:50 +0000 Subject: [PATCH] ICU-699 comment out broken clone tests, to unblock 3357 (int64) testing. X-SVN-Rev: 13584 --- icu4c/source/test/intltest/loctest.cpp | 3 +++ icu4c/source/test/intltest/pptest.cpp | 6 ++++++ icu4c/source/test/intltest/restsnew.cpp | 5 ++++- icu4c/source/test/intltest/srchtest.cpp | 4 ++++ icu4c/source/test/intltest/tfsmalls.cpp | 6 +++++- 5 files changed, 22 insertions(+), 2 deletions(-) diff --git a/icu4c/source/test/intltest/loctest.cpp b/icu4c/source/test/intltest/loctest.cpp index 19f77fbba3..41324227ea 100644 --- a/icu4c/source/test/intltest/loctest.cpp +++ b/icu4c/source/test/intltest/loctest.cpp @@ -302,12 +302,15 @@ void LocaleTest::TestBasicGetters() { errln("assignment to bogus Locale does not unbogus it or sets bad data"); } + errln("%s:%d: clone test commented out..\n", __FILE__, __LINE__); +#if 0 Locale a("eo_DE@currency=DEM"); Locale *pb=a.clone(); if(pb==&a || *pb!=a) { errln("Locale.clone() failed"); } delete pb; +#endif } void LocaleTest::TestParallelAPIValues() { diff --git a/icu4c/source/test/intltest/pptest.cpp b/icu4c/source/test/intltest/pptest.cpp index 61ec4e78d4..de753a6d3a 100644 --- a/icu4c/source/test/intltest/pptest.cpp +++ b/icu4c/source/test/intltest/pptest.cpp @@ -91,11 +91,14 @@ void ParsePositionTest::TestParsePosition() errln("*** PP operator= operator== or operator != result"); } + errln("%s:%d: clone test commented out..\n", __FILE__, __LINE__); +#if 0 ParsePosition *ppp = pp5.clone(); if(ppp == &pp5 || *ppp != pp5) { errln("ParsePosition.clone() failed"); } delete ppp; +#endif } void ParsePositionTest::TestFieldPosition() @@ -148,11 +151,14 @@ void ParsePositionTest::TestFieldPosition() logln(""); + errln("%s:%d: clone test commented out..\n", __FILE__, __LINE__); +#if 0 FieldPosition *pfp = fp.clone(); if(pfp == &fp || *pfp != fp) { errln("FieldPosition.clone() failed"); } delete pfp; +#endif } void ParsePositionTest::TestFieldPosition_example() diff --git a/icu4c/source/test/intltest/restsnew.cpp b/icu4c/source/test/intltest/restsnew.cpp index 72d7da05ec..8ce5d7a610 100644 --- a/icu4c/source/test/intltest/restsnew.cpp +++ b/icu4c/source/test/intltest/restsnew.cpp @@ -456,7 +456,9 @@ NewResourceBundleTest::TestOtherAPI(){ ResourceBundle *p; - p = defaultresource.clone(); + errln("%s:%d: clone test commented out..\n", __FILE__, __LINE__); +#if 0 + r = defaultresource.clone(); if(p == &defaultresource || !equalRB(*p, defaultresource)) { errln("ResourceBundle.clone() failed"); } @@ -467,6 +469,7 @@ NewResourceBundleTest::TestOtherAPI(){ errln("2nd ResourceBundle.clone() failed"); } delete p; +#endif UVersionInfo ver; copyRes.getVersion(ver); diff --git a/icu4c/source/test/intltest/srchtest.cpp b/icu4c/source/test/intltest/srchtest.cpp index 6408352092..210036209b 100644 --- a/icu4c/source/test/intltest/srchtest.cpp +++ b/icu4c/source/test/intltest/srchtest.cpp @@ -379,6 +379,9 @@ UBool StringSearchTest::assertEqual(const SearchData *search) return FALSE; } + + errln("%s:%d: clone test commented out..\n", __FILE__, __LINE__); +#if 0 strsrch2 = strsrch->clone(); if( strsrch2 == strsrch || *strsrch2 != *strsrch || !assertEqualWithStringSearch(strsrch2, search) @@ -390,6 +393,7 @@ UBool StringSearchTest::assertEqual(const SearchData *search) return FALSE; } delete strsrch2; +#endif collator->setStrength(getECollationStrength(UCOL_TERTIARY)); delete strsrch; diff --git a/icu4c/source/test/intltest/tfsmalls.cpp b/icu4c/source/test/intltest/tfsmalls.cpp index 584be6f0ee..0e6ad5bfc4 100644 --- a/icu4c/source/test/intltest/tfsmalls.cpp +++ b/icu4c/source/test/intltest/tfsmalls.cpp @@ -244,6 +244,9 @@ void test_Formattable( void ) it_errln(UnicodeString("*** FT getArray count res_cnt=") + res_cnt + UnicodeString("ft_cnt=") + ft_cnt); } + + it_errln(UnicodeString("tfsmalls.cpp:") + __LINE__ + ": clone test commented out..\n"); +#if 0 Formattable *pf; for(i = 0; i < ft_cnt; ++i) { pf = ftarray[i].clone(); @@ -252,6 +255,7 @@ void test_Formattable( void ) } delete pf; } +#endif const Formattable ftarr1[] = { Formattable( (int32_t)1 ), Formattable( (int32_t)2 ) }; const Formattable ftarr2[] = { Formattable( (int32_t)3 ), Formattable( (int32_t)4 ) }; @@ -267,7 +271,7 @@ void test_Formattable( void ) } Formattable* ft_dynarr = new Formattable[ftarr2_cnt]; - for (int32_t i = 0; i < ftarr2_cnt; i++ ) { + for (i = 0; i < ftarr2_cnt; i++ ) { ft_dynarr[i] = ftarr2[i]; } if ((ft_dynarr[0].getType() == Formattable::kLong) && (ft_dynarr[0].getLong() == (int32_t)3)