mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
middle matching with uppercase prefix
This commit is contained in:
@@ -215,6 +215,8 @@ public class NameUtilTest extends UsefulTestCase {
|
||||
}
|
||||
|
||||
public void testMiddleMatching() {
|
||||
assertTrue(caseInsensitiveMatcher("*OLD").matches("folder"));
|
||||
assertTrue(caseInsensitiveMatcher("*old").matches("folder"));
|
||||
assertMatches("SWU*H*7", "SWUpgradeHdlrFSPR7Test");
|
||||
assertMatches("SWU*H*R", "SWUpgradeHdlrFSPR7Test");
|
||||
assertMatches("SWU*H*R", "SWUPGRADEHDLRFSPR7TEST");
|
||||
@@ -222,7 +224,7 @@ public class NameUtilTest extends UsefulTestCase {
|
||||
assertMatches("*Git", "GitBlaBla");
|
||||
assertMatches("*git", "BlaGitBla");
|
||||
assertMatches("*Git", "BlaGitBla");
|
||||
assertDoesntMatch("*Git", "BlagitBla");
|
||||
assertFalse(firstLetterMatcher("*Git").matches("BlagitBla"));
|
||||
assertMatches("*git", "BlagitBla");
|
||||
assertMatches("*Git*", "AtpGenerationItem");
|
||||
assertMatches("Collec*Util*", "CollectionUtils");
|
||||
|
||||
@@ -193,7 +193,7 @@ public class MinusculeMatcher implements Matcher {
|
||||
if (next < 0) {
|
||||
break;
|
||||
}
|
||||
if (upper && next > 0 && !Character.isUpperCase(name.charAt(next))) {
|
||||
if (upper && next > 0 && !Character.isUpperCase(name.charAt(next)) && myOptions != NameUtil.MatchingCaseSensitivity.NONE) {
|
||||
fromIndex = next + 1;
|
||||
continue;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user