How to configure completion match case setting in unit tests?

Answered

I'm writting unit tests for code completion features, but when I debugged to MinusculeMatcherImpl#isFirstCharMatching:

if (myOptions == NameUtil.MatchingCaseSensitivity.FIRST_LETTER &&
(patternIndex == 0 || patternIndex == 1 && isWildcard(0)) &&
hasCase(patternChar) &&
Character.isUpperCase(patternChar) != Character.isUpperCase(name.charAt(0))) {
return false;
}

It seems that Match case setting of Code Completion is set to "First letter only" by default.

It takes me some time to debug but I still don't know how to set it to "None" in my tests.  I will be thankful for any advice.

2 comments
Comment actions Permalink

com.intellij.codeInsight.CodeInsightSettings#setCompletionCaseSensitive

Make sure to reset it in finally {} block

0
Comment actions Permalink

I'm too blind to see this setting, thank you sooooo much!

0

Please sign in to leave a comment.