ICU-7240 Fixed collation test failures after UUCS5.2 upgrade.

X-SVN-Rev: 26962
This commit is contained in:
Claire Ho 2009-11-21 00:37:52 +00:00
parent 1e29b2a88c
commit ccb5efefb0
2 changed files with 9 additions and 11 deletions

View file

@ -147,8 +147,8 @@ final class CollationParsedRuleBuilder {
if (s1 == t1 && s2 == t2) {
return 0;
}
s = (s1 & 0xFFFF0000) | ((s2 & 0xFFFF0000) >> 16);
t = (t1 & 0xFFFF0000) | ((t2 & 0xFFFF0000) >> 16);
s = (s1 & 0xFFFF0000) | ((s2 & 0xFFFF0000) >>> 16);
t = (t1 & 0xFFFF0000) | ((t2 & 0xFFFF0000) >>> 16);
if (s == t) {
s = (s1 & 0x0000FF00) | (s2 & 0x0000FF00) >> 8;
t = (t1 & 0x0000FF00) | (t2 & 0x0000FF00) >> 8;

View file

@ -130,9 +130,6 @@ public class CollationMiscTest extends TestFmwk {
}
public void TestRuleOptions() {
if(skipIfBeforeICU(4,3,3)) {
return; // TODO: Fix me!
}
// values here are hardcoded and are correct for the current UCA when
// the UCA changes, one might be forced to change these values.
// (\\u02d0, \\U00010FFFC etc...)
@ -169,7 +166,12 @@ public class CollationMiscTest extends TestFmwk {
{"c", "b", "\\u0009", "a", "\\u000a"},
{"c", "b", "\\uD834\\uDF71", "a", "\\u02d0"},
{"b", "\\u02d0", "a", "\\u02d1"},
{"b", "\\ud808\\udf6e", "a", "\\u4e00"},
// The character in the second ordering test string
// has to match the character that has the [last regular] weight
// which changes with each UCA version.
// See the bottom of FractionalUCA.txt which says something like
// [last regular [CE 27, 05, 05]] # U+1342E EGYPTIAN HIEROGLYPH AA032
{"b", "\\U0001342E", "a", "\\u4e00"},
{"b", "\\u4e00", "a", "\\u4e01"},
{"b", "\\U0010FFFD", "a"},
{"\ufffb", "w", "y", "\u20e3", "x", "\u137c", "z", "u"},
@ -304,9 +306,6 @@ public class CollationMiscTest extends TestFmwk {
}
public void TestBeforePrefixFailure() {
if(skipIfBeforeICU(4,3,3)) {
return; // TODO: Fix me!
}
String[] rules = {
"&g <<< a&[before 3]\uff41 <<< x",
"&\u30A7=\u30A7=\u3047=\uff6a&\u30A8=\u30A8=\u3048=\uff74&[before 3]\u30a7<<<\u30a9",
@ -2601,5 +2600,4 @@ public class CollationMiscTest extends TestFmwk {
"for two different RawCollationKey objects.");
}
}
}
}