mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-15 11:53:49 +07:00
[Java. Logging] Add NeedsIndex annotation to pass the test
IDEA-345098 GitOrigin-RevId: a6190b0e43a49769ee59c50eee6450c121a43ecb
This commit is contained in:
committed by
intellij-monorepo-bot
parent
57ef1be2f2
commit
effcc65b0a
@@ -6,40 +6,48 @@ import com.intellij.codeInsight.CodeInsightSettings
|
||||
import com.intellij.codeInsight.completion.JvmLoggerLookupElement
|
||||
import com.intellij.codeInsight.completion.LightFixtureCompletionTestCase
|
||||
import com.intellij.java.codeInsight.JvmLoggerTestSetupUtil
|
||||
import com.intellij.testFramework.NeedsIndex
|
||||
import junit.framework.TestCase
|
||||
|
||||
class LoggerCompletionTest : LightFixtureCompletionTestCase() {
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testSlf4j() {
|
||||
JvmLoggerTestSetupUtil.setupSlf4j(myFixture)
|
||||
doTest(1, "long", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testLog4j2() {
|
||||
JvmLoggerTestSetupUtil.setupLog4j2(myFixture)
|
||||
doTest(1, "long", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testLog4j() {
|
||||
JvmLoggerTestSetupUtil.setupLog4j(myFixture)
|
||||
doTest(1, "long", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testApacheCommons() {
|
||||
JvmLoggerTestSetupUtil.setupApacheCommons(myFixture)
|
||||
doTest(1, "long", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testNestedClasses() {
|
||||
JvmLoggerTestSetupUtil.setupSlf4j(myFixture)
|
||||
doTest(1, "long", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testMultipleLoggers() {
|
||||
JvmLoggerTestSetupUtil.setupSlf4j(myFixture)
|
||||
JvmLoggerTestSetupUtil.setupLog4j2(myFixture)
|
||||
doTest(2, "long", "log", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testLoggerAlreadyExists() {
|
||||
JvmLoggerTestSetupUtil.setupSlf4j(myFixture)
|
||||
val name = getTestName(false)
|
||||
@@ -53,11 +61,13 @@ class LoggerCompletionTest : LightFixtureCompletionTestCase() {
|
||||
)
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testStaticQualifierWithLocalVariable() {
|
||||
JvmLoggerTestSetupUtil.setupSlf4j(myFixture)
|
||||
doTest(2, "log", "long", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testAutoCompletionAfterDot() {
|
||||
var isAutoComplete = true
|
||||
try {
|
||||
|
||||
@@ -4,29 +4,35 @@ import com.intellij.codeInsight.completion.JvmLoggerLookupElement
|
||||
import com.intellij.codeInsight.completion.LightFixtureCompletionTestCase
|
||||
import com.intellij.java.codeInsight.JvmLoggerTestSetupUtil
|
||||
import com.intellij.testFramework.LightProjectDescriptor
|
||||
import com.intellij.testFramework.NeedsIndex
|
||||
import de.plushnikov.intellij.plugin.LombokTestUtil
|
||||
import de.plushnikov.intellij.plugin.logging.LombokLoggingUtils
|
||||
import junit.framework.TestCase
|
||||
|
||||
class LombokLoggerCompletionTest : LightFixtureCompletionTestCase() {
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testSlf4j() {
|
||||
JvmLoggerTestSetupUtil.setupSlf4j(myFixture)
|
||||
|
||||
doTest(LombokLoggingUtils.SLF4J_ANNOTATION, "long", "log", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testLog4j2() {
|
||||
JvmLoggerTestSetupUtil.setupLog4j2(myFixture)
|
||||
|
||||
doTest(LombokLoggingUtils.LOG4J2_ANNOTATION, "long", "log", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testLog4j() {
|
||||
JvmLoggerTestSetupUtil.setupLog4j(myFixture)
|
||||
|
||||
doTest(LombokLoggingUtils.LOG4J_ANNOTATION, "long", "log", "log", "clone")
|
||||
}
|
||||
|
||||
@NeedsIndex.SmartMode(reason = "Logger completion is not supported in the dumb mode")
|
||||
fun testApacheCommons() {
|
||||
JvmLoggerTestSetupUtil.setupApacheCommons(myFixture)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user