- logln("Data line %s", lineB);
- prettify(CollationKey(oldSk, oldLen), oldS);
- prettify(CollationKey(newSk, resLen), newS);
- logln("Keys: "+oldS+" and "+newS);
- } else if(res == 0) { /* equal */
- res = u_strcmpCodePointOrder(oldB, buffer);
- if (res == 0) {
- errln("Probable error in test file on line %i (comparing identical strings)", line);
- logln("Data line %s", lineB);
- } else if (res > 0) {
- errln("Sortkeys are identical, but code point comapare gives >0 on line %i", line);
- logln("Data line %s", lineB);
+ ok = FALSE;
+ }
+
+ if(!ok) {
+ errln(" Previous data line %s", oldLineB);
+ errln(" Current data line %s", lineB);
+ if(withSortKeys) {
+ UnicodeString oldS, newS;
+ prettify(CollationKey(oldSk, oldLen), oldS);
+ prettify(CollationKey(newSk, resLen), newS);
+ errln(" Previous key: "+oldS);
+ errln(" Current key: "+newS);