Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 0 additions & 30 deletions muted-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -498,36 +498,6 @@ tests:
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.WildcardLikeTests
method: testEvaluateInManyThreads {TestCase=100 random code points matches self case insensitive with text}
issue: https://github.com/elastic/elasticsearch/issues/128677
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.RLikeTests
method: testEvaluateInManyThreads {TestCase=100 random code points matches self case insensitive with text}
issue: https://github.com/elastic/elasticsearch/issues/128705
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.RLikeTests
method: testEvaluateInManyThreads {TestCase=100 random code points matches self case insensitive with keyword}
issue: https://github.com/elastic/elasticsearch/issues/128706
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.RLikeTests
method: testCrankyEvaluateBlockWithNulls {TestCase=100 random code points matches self case insensitive with text}
issue: https://github.com/elastic/elasticsearch/issues/128710
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.RLikeTests
method: testCrankyEvaluateBlockWithNulls {TestCase=100 random code points matches self case insensitive with keyword}
issue: https://github.com/elastic/elasticsearch/issues/128711
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.WildcardLikeTests
method: testCrankyEvaluateBlockWithNulls {TestCase=100 random code points matches self case insensitive with text}
issue: https://github.com/elastic/elasticsearch/issues/128712
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.WildcardLikeTests
method: testCrankyEvaluateBlockWithNulls {TestCase=100 random code points matches self case insensitive with keyword}
issue: https://github.com/elastic/elasticsearch/issues/128713
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.WildcardLikeTests
method: testEvaluateBlockWithNulls {TestCase=100 random code points matches self case insensitive with text}
issue: https://github.com/elastic/elasticsearch/issues/128714
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.WildcardLikeTests
method: testEvaluateBlockWithNulls {TestCase=100 random code points matches self case insensitive with keyword}
issue: https://github.com/elastic/elasticsearch/issues/128715
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.RLikeTests
method: testEvaluateBlockWithNulls {TestCase=100 random code points matches self case insensitive with keyword}
issue: https://github.com/elastic/elasticsearch/issues/128716
- class: org.elasticsearch.xpack.esql.expression.function.scalar.string.RLikeTests
method: testEvaluateBlockWithNulls {TestCase=100 random code points matches self case insensitive with text}
issue: https://github.com/elastic/elasticsearch/issues/128717
- class: org.elasticsearch.compute.operator.LimitOperatorTests
method: testEarlyTermination
issue: https://github.com/elastic/elasticsearch/issues/128721
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,15 @@ private static void casesForString(
return new TextAndPattern(text, escapeString.apply(text));
}, true);
cases(cases, title + " matches self case insensitive", () -> {
String text = textSupplier.get();
return new TextAndPattern(randomCasing(text), escapeString.apply(text));
// RegExp doesn't support case-insensitive matching for Unicodes whose length changes when the case changes.
// Example: a case-insensitive ES regexp query for the pattern `weiß` won't match the value `WEISS` (but will match `WEIß`).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The example is super useful, thank you!

// Or `ʼn` (U+0149) vs. `ʼN` (U+02BC U+004E).
String text, caseChanged;
for (text = textSupplier.get(), caseChanged = randomCasing(text); text.length() != caseChanged.length();) {
text = textSupplier.get();
caseChanged = randomCasing(text);
}
return new TextAndPattern(caseChanged, escapeString.apply(text));
}, true, true);
cases(cases, title + " doesn't match self with trailing", () -> {
String text = textSupplier.get();
Expand Down