mirror of https://github.com/apache/lucene.git
Fix TestSort.testRandomFieldNameSorts typo that ccaused very sporadic but reproducible failures
This commit is contained in:
parent
a8fc069395
commit
92cf9d8758
|
@ -111,8 +111,8 @@ public class TestSort extends SolrTestCaseJ4 {
|
||||||
names[j] = TestUtil.randomRealisticUnicodeString(r, 1, 100);
|
names[j] = TestUtil.randomRealisticUnicodeString(r, 1, 100);
|
||||||
|
|
||||||
// munge anything that might make this a function
|
// munge anything that might make this a function
|
||||||
names[j] = names[j].replaceFirst("\\{","\\{\\{");
|
names[j] = names[j].replaceFirst("\\{","\\}\\{");
|
||||||
names[j] = names[j].replaceFirst("\\(","\\(\\(");
|
names[j] = names[j].replaceFirst("\\(","\\)\\(");
|
||||||
names[j] = names[j].replaceFirst("(\\\"|\\')","$1$1z");
|
names[j] = names[j].replaceFirst("(\\\"|\\')","$1$1z");
|
||||||
names[j] = names[j].replaceFirst("(\\d)","$1x");
|
names[j] = names[j].replaceFirst("(\\d)","$1x");
|
||||||
|
|
||||||
|
@ -162,7 +162,8 @@ public class TestSort extends SolrTestCaseJ4 {
|
||||||
assertEquals("sorts["+j+"] is (unexpectedly) type doc : " + input,
|
assertEquals("sorts["+j+"] is (unexpectedly) type doc : " + input,
|
||||||
"_docid_", names[j]);
|
"_docid_", names[j]);
|
||||||
} else if (Type.CUSTOM.equals(type) || Type.REWRITEABLE.equals(type)) {
|
} else if (Type.CUSTOM.equals(type) || Type.REWRITEABLE.equals(type)) {
|
||||||
|
log.error("names[{}] : {}", j, names[j]);
|
||||||
|
log.error("sorts[{}] : {}", j, sorts[j]);
|
||||||
fail("sorts["+j+"] resulted in a '" + type.toString()
|
fail("sorts["+j+"] resulted in a '" + type.toString()
|
||||||
+ "', either sort parsing code is broken, or func/query "
|
+ "', either sort parsing code is broken, or func/query "
|
||||||
+ "semantics have gotten broader and munging in this test "
|
+ "semantics have gotten broader and munging in this test "
|
||||||
|
|
Loading…
Reference in New Issue