ICU-5410 Add a test to improve code coverage.

X-SVN-Rev: 20513
This commit is contained in:
George Rhoten 2006-10-06 22:55:16 +00:00
parent adbc92774a
commit a1f2781f54

View File

@ -21,6 +21,7 @@ import com.ibm.icu.impl.InvalidFormatException;
import com.ibm.icu.impl.Utility;
import com.ibm.icu.text.UnicodeSet;
import com.ibm.icu.util.ByteArrayWrapper;
import com.ibm.icu.util.CaseInsensitiveString;
/**
* @test
@ -218,4 +219,15 @@ public class UtilityTest extends TestFmwk {
logln("Assert.fail works");
}
}
public void TestCaseInsensitiveString() {
CaseInsensitiveString str1 = new CaseInsensitiveString("ThIs is A tEst");
CaseInsensitiveString str2 = new CaseInsensitiveString("This IS a test");
if (!str1.equals(str2)
|| !str1.toString().equals(str1.getString())
|| str1.toString().equals(str2.toString()))
{
errln("FAIL: str1("+str1+") != str2("+str2+")");
}
}
}